Commit | Line | Data |
---|---|---|
992de934 GM |
1 | /* |
2 | * | |
3 | * @(#)dohits.h 1.3 (Berkeley) %G% | |
4 | */ | |
5 | ||
d9416b81 GM |
6 | #define numberof(x) (sizeof x/sizeof x[0]) |
7 | #define highestof(x) (numberof(x)-1) | |
8 | ||
9 | #define firstentry(x) (table[dohash(0, (x))%highestof(table)]) | |
10 | ||
bfbc528f | 11 | struct Hits { |
d9416b81 GM |
12 | struct hits hits; |
13 | char *name[4]; | |
14 | }; | |
15 | ||
16 | struct thing { | |
17 | struct thing *next; | |
18 | struct Hits *hits; | |
19 | unsigned char value; | |
20 | char name[100]; | |
21 | }; | |
22 | ||
23 | extern struct Hits Hits[256]; /* one for each of 0x00-0xff */ | |
24 | extern struct thing *table[100]; | |
25 | ||
26 | extern unsigned int dohash(); |