home *** CD-ROM | disk | FTP | other *** search
/ NeXTSTEP 3.0 / NeXTSTEP3.0.iso / NextDeveloper / Headers / bsd / netinet / udp_var.h < prev    next >
C/C++ Source or Header  |  1992-07-29  |  1KB  |  53 lines

  1. /*
  2.  * Copyright (c) 1982, 1986 Regents of the University of California.
  3.  * All rights reserved.
  4.  *
  5.  * Redistribution and use in source and binary forms are permitted
  6.  * provided that this notice is preserved and that due credit is given
  7.  * to the University of California at Berkeley. The name of the University
  8.  * may not be used to endorse or promote products derived from this
  9.  * software without specific prior written permission. This software
  10.  * is provided ``as is'' without express or implied warranty.
  11.  *
  12.  *    @(#)udp_var.h    7.3 (Berkeley) 12/7/87
  13.  */
  14.  
  15. /*
  16.  * UDP kernel structures and variables.
  17.  */
  18. struct    udpiphdr {
  19.     struct     ipovly ui_i;        /* overlaid ip structure */
  20.     struct    udphdr ui_u;        /* udp header */
  21. };
  22. #define    ui_next        ui_i.ih_next
  23. #define    ui_prev        ui_i.ih_prev
  24. #define    ui_x1        ui_i.ih_x1
  25. #define    ui_pr        ui_i.ih_pr
  26. #define    ui_len        ui_i.ih_len
  27. #define    ui_src        ui_i.ih_src
  28. #define    ui_dst        ui_i.ih_dst
  29. #define    ui_sport    ui_u.uh_sport
  30. #define    ui_dport    ui_u.uh_dport
  31. #define    ui_ulen        ui_u.uh_ulen
  32. #define    ui_sum        ui_u.uh_sum
  33.  
  34. struct    udpstat {
  35.     int    udps_hdrops;
  36.     int    udps_badsum;
  37.     int    udps_badlen;
  38. };
  39.  
  40. #if    NeXT
  41. /*
  42.  * The Internet has grown bigger than 30 hops.
  43.  */
  44. #define    UDP_TTL        60        /* deflt time to live for UDP packets */
  45. #else    NeXT
  46. #define    UDP_TTL        30        /* deflt time to live for UDP packets */
  47. #endif    NeXT
  48.  
  49. #ifdef KERNEL
  50. struct    inpcb udb;
  51. struct    udpstat udpstat;
  52. #endif
  53.