home *** CD-ROM | disk | FTP | other *** search
/ ftp.wwiv.com / ftp.wwiv.com.zip / ftp.wwiv.com / pub / PPPBCKP / SRC / SRC15B94.ZIP / TCP.H < prev    next >
C/C++ Source or Header  |  1998-10-31  |  2KB  |  91 lines

  1.  
  2. /*
  3.  * Waterloo TCP
  4.  *
  5.  * Copyright (c) 1990, 1991, 1992, 1993 Erick Engelke
  6.  *
  7.  * Portions copyright others, see copyright.h for details.
  8.  *
  9.  * This library is free software; you can use it or redistribute under
  10.  * the terms of the license included in LICENSE.H.
  11.  *
  12.  * This program is distributed in the hope that it will be useful,
  13.  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  14.  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  15.  * file LICENSE.H for more details.
  16.  *
  17.  */
  18. #ifndef _wattcp_tcp_h
  19. #define _wattcp_tcp_h
  20.  
  21. #ifndef WTCP_VER
  22.  
  23. #define __WATTCP_USER__  /* Not compiling the kernel itself, hide some stuff */
  24.  
  25. #include "wattcp.h"
  26.  
  27. /* Kernal version (major major minor minor) */
  28. #define WTCP_VER 0x0102
  29.  
  30. /*
  31.  * Typedefs and constants
  32.  */
  33.  
  34. typedef struct in_addr {
  35.     longword    s_addr;
  36. };
  37.  
  38. /*
  39.  * BSD-style socket info routines -- bsdname.c
  40.  */
  41. int getpeername( sock_type *s, void *dest, int *len );
  42. int getsockname(  sock_type *s, void *dest, int *len );
  43. char *getdomainname( char *name, int length );
  44. char *setdomainname( char *string );
  45. char *gethostname( char *name, int len );
  46. char *sethostname( char *name );
  47. void psocket( sock_type *s );
  48.  
  49. /*
  50.  * ICMP-related stuff -- pcicmp.c
  51.  */
  52. /*
  53.  * Send an icmp echo request using specified ttl and tos.
  54.  * if(icmp_id != NULL) store copy of the id there
  55.  */
  56. int _send_ping( longword host, longword countnum, byte ttl,
  57.                                             byte tos, longword *theid );
  58. /* backward compatibility */
  59. #define _ping( h, c ) _send_ping( h, c, 250, 0, NULL )
  60. longword _chk_ping( longword host , longword *ptr);
  61.  
  62. /*
  63.  * Daemons -- wattcpd.c
  64.  */
  65. int addwattcpd( void (*p)( void ) );
  66. int delwattcpd( void (*p)( void ) );
  67.  
  68. /*
  69.  * Background net I/O processing -- netback.c
  70.  */
  71. void backgroundon( void );
  72. void backgroundoff(void);
  73. void backgroundfn( void (*fn)() );
  74.  
  75. /*
  76.  * More background processing -- pcintr.c
  77.  */
  78. void wintr_enable( void );
  79. void wintr_disable( void );
  80. void wintr_shutdown( void );
  81. void wintr_init( void );
  82.  
  83. /*
  84.  * Socket stats -- pcstat.c
  85.  */
  86. int sock_stats( sock_type *s, word *days, word *inactive, word *cwindow, word *avg, word *sd );
  87.  
  88. #endif /* WTCP_VER */
  89.  
  90. #endif /* ndef _wattcp_tcp_h */
  91.