/* C code produced by gperf version 2.1 (K&R C version) */ /* Command-line: gperf -aptCT -N in_word_set_portoption portoption.list */ #include "config.h" #ifdef HAVE_STRING_H #include #endif /* HAVE_STRING_H */ #include "Config.h" #define MIN_WORD_LENGTH 3 #define MAX_WORD_LENGTH 6 #define MIN_HASH_VALUE 3 #define MAX_HASH_VALUE 6 /* 2 keywords 4 is the maximum key range */ static int hash (register const char *str, register int len) { static const unsigned char hash_table[] = { 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 0, 6, 6, 6, 6, 6, 6, 0, 6, 6, 0, 6, 6, 0, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, }; return len + hash_table[str[len - 1]] + hash_table[str[0]]; } const PORTOPTION* in_word_set_portoption (register const char *str, register int len) { static const PORTOPTION wordlist[] = { {"",}, {"",}, {"",}, {"SSL", PO_SSL}, {"",}, {"",}, {"VERIFY", PO_VERIFY}, }; if (len <= MAX_WORD_LENGTH && len >= MIN_WORD_LENGTH) { register int key = hash (str, len); if (key <= MAX_HASH_VALUE && key >= MIN_HASH_VALUE) { register const char *s = wordlist[key].name; if (*s == *str && !strcmp (str + 1, s + 1)) return &wordlist[key]; } } return 0; }