home *** CD-ROM | disk | FTP | other *** search
/ Usenet 1994 January / usenetsourcesnewsgroupsinfomagicjanuary1994.iso / sources / unix / volume25 / ethertop / ethertop.h < prev    next >
Encoding:
C/C++ Source or Header  |  1991-12-12  |  1.5 KB  |  63 lines

  1. /*
  2.  * Copyright (c) 1991 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 the above copyright notice and this paragraph are
  7.  * duplicated in all such forms and that any documentation,
  8.  * advertising materials, and other materials related to such
  9.  * distribution and use acknowledge that the software was developed
  10.  * by the University of California, Irvine.  The name of the
  11.  * University may not be used to endorse or promote products derived
  12.  * from this software without specific prior written permission.
  13.  * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
  14.  * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
  15.  * WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
  16.  */
  17. #include <rpc/rpc.h>
  18. #undef h_addr
  19. #include "ether.h"
  20.  
  21.  
  22. struct etherfloat_node {
  23.     int h_addr;
  24.     float h_cnt;
  25. };
  26. typedef struct etherfloat_node etherfloat_node;
  27. extern displayip;
  28. extern char *server;
  29. extern struct timeval timeout;
  30. extern total;
  31. char *inet_ntoa();
  32. char *gethostnamebyip();
  33. void init_gethostnamebyip();
  34. struct host_ip_ent
  35. {
  36.   int h_addr;
  37.   char *h_name;
  38.   struct host_ip_ent *h_nxt;
  39. };
  40.  
  41. typedef struct host_ip_ent host_ip_ent;
  42. #define H2IP_HASH_SIZE 0x2000
  43. #define H2IP_HASH_MASK 0x1FFF
  44.  
  45. struct etherfloatstat {
  46.     float e_time;
  47.     float e_bytes;
  48.     float e_packets;
  49.     float e_bcast;
  50.     float e_size[NBUCKETS];
  51.     float e_proto[NPROTOS];
  52. };
  53. typedef struct etherfloatstat etherfloatstat;
  54.  
  55.  
  56.  
  57.  
  58.  
  59.  
  60.  
  61.  
  62.  
  63.