/contrib/ntp/include/parse_conf.h

https://bitbucket.org/freebsd/freebsd-head/ · C Header · 83 lines · 30 code · 6 blank · 47 comment · 1 complexity · 998df6b1e83e5939d498d64a079ae02e MD5 · raw file

  1. /*
  2. * /src/NTP/ntp4-dev/include/parse_conf.h,v 4.7 2005/06/25 10:58:45 kardel RELEASE_20050625_A
  3. *
  4. * parse_conf.h,v 4.7 2005/06/25 10:58:45 kardel RELEASE_20050625_A
  5. *
  6. * Copyright (c) 1995-2005 by Frank Kardel <kardel <AT> ntp.org>
  7. * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universität Erlangen-Nürnberg, Germany
  8. *
  9. * Redistribution and use in source and binary forms, with or without
  10. * modification, are permitted provided that the following conditions
  11. * are met:
  12. * 1. Redistributions of source code must retain the above copyright
  13. * notice, this list of conditions and the following disclaimer.
  14. * 2. Redistributions in binary form must reproduce the above copyright
  15. * notice, this list of conditions and the following disclaimer in the
  16. * documentation and/or other materials provided with the distribution.
  17. * 3. Neither the name of the author nor the names of its contributors
  18. * may be used to endorse or promote products derived from this software
  19. * without specific prior written permission.
  20. *
  21. * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  22. * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  23. * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  24. * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
  25. * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  26. * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  27. * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  28. * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  29. * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  30. * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  31. * SUCH DAMAGE.
  32. *
  33. */
  34. #ifndef __PARSE_CONF_H__
  35. #define __PARSE_CONF_H__
  36. #if !(defined(lint) || defined(__GNUC__))
  37. static char prshrcsid[] = "parse_conf.h,v 4.7 2005/06/25 10:58:45 kardel RELEASE_20050625_A";
  38. #endif
  39. /*
  40. * field location structure
  41. */
  42. #define O_DAY 0
  43. #define O_MONTH 1
  44. #define O_YEAR 2
  45. #define O_HOUR 3
  46. #define O_MIN 4
  47. #define O_SEC 5
  48. #define O_WDAY 6
  49. #define O_FLAGS 7
  50. #define O_ZONE 8
  51. #define O_UTCHOFFSET 9
  52. #define O_UTCMOFFSET 10
  53. #define O_UTCSOFFSET 11
  54. #define O_COUNT (O_UTCSOFFSET+1)
  55. #define MBG_EXTENDED 0x00000001
  56. /*
  57. * see below for field offsets
  58. */
  59. struct format
  60. {
  61. struct foff
  62. {
  63. unsigned short offset; /* offset into buffer */
  64. unsigned short length; /* length of field */
  65. } field_offsets[O_COUNT];
  66. const unsigned char *fixed_string; /* string with must be chars (blanks = wildcards) */
  67. u_long flags;
  68. };
  69. #endif
  70. /*
  71. * History:
  72. *
  73. * parse_conf.h,v
  74. * Revision 4.7 2005/06/25 10:58:45 kardel
  75. * add missing log keywords
  76. *
  77. */