141edb306SCy Schubert /* 241edb306SCy Schubert * Copyright (C) 2012 by Darren Reed. 341edb306SCy Schubert * 441edb306SCy Schubert * See the IPFILTER.LICENCE file for details on licencing. 541edb306SCy Schubert * 641edb306SCy Schubert * $Id: findword.c,v 1.3.4.1 2012/07/22 08:04:24 darren_r Exp $ 741edb306SCy Schubert */ 841edb306SCy Schubert 941edb306SCy Schubert #include "ipf.h" 1041edb306SCy Schubert 1141edb306SCy Schubert 12efeb8bffSCy Schubert wordtab_t * findword(wordtab_t * words,char * name)13efeb8bffSCy Schubertfindword(wordtab_t *words, char *name) 1441edb306SCy Schubert { 1541edb306SCy Schubert wordtab_t *w; 1641edb306SCy Schubert 1741edb306SCy Schubert for (w = words; w->w_word != NULL; w++) 1841edb306SCy Schubert if (!strcmp(name, w->w_word)) 1941edb306SCy Schubert break; 2041edb306SCy Schubert if (w->w_word == NULL) 21*2582ae57SCy Schubert return (NULL); 2241edb306SCy Schubert 23*2582ae57SCy Schubert return (w); 2441edb306SCy Schubert } 25