FACT++  1.0
SERVICE* dis_hash_service_exists ( char *  name)

Definition at line 3296 of file dis.c.

References dll_search(), HashFunction(), and MAX_HASH_ENTRIES.

Referenced by find_service().

3297 {
3298  int index;
3299  SERVICE *servp;
3300 
3301  index = HashFunction(name, MAX_HASH_ENTRIES);
3302  if(!Service_hash_table[index])
3303  {
3304  return((SERVICE *)0);
3305  }
3306  if( (servp = (SERVICE *) dll_search(
3307  (DLL *) Service_hash_table[index],
3308  name, (int)strlen(name)+1)) )
3309  {
3310  return(servp);
3311  }
3312  return((SERVICE *)0);
3313 }
#define MAX_HASH_ENTRIES
Definition: dis.c:3231
Definition: dim.h:530
Definition: dis.c:69
static SERVICE * Service_hash_table[MAX_HASH_ENTRIES]
Definition: dis.c:3233
int HashFunction(char *name, int max)
Definition: hash.c:22
DLL * dll_search(DLL *head, char *data, int size)
Definition: dll.c:49

+ Here is the call graph for this function:

+ Here is the caller graph for this function: