7fd59977 |
1 | /* Returns a unique number according to the string passed as 1fst argument */ |
2 | |
3 | int osd_getkey(char *name) |
4 | { |
5 | int ii = 0; |
6 | register char *pp; |
7 | |
8 | pp = name; |
9 | while( *pp ) ii = ii << 1 ^ *pp++; |
10 | if( ii < 0 ) ii = -ii; |
11 | |
12 | return ii; |
13 | } |