dmake: do not set MAKEFLAGS=k
[unleashed/tickless.git] / usr / src / cmd / ipf / lib / common / optvalue.c
blob21d37b4d012cefded7c87c19ec4b678bc9c6e337
1 /*
2 * Copyright (C) 1993-2001 by Darren Reed.
4 * See the IPFILTER.LICENCE file for details on licencing.
6 * $Id: optvalue.c,v 1.2 2002/01/28 06:50:47 darrenr Exp $
7 */
8 #include "ipf.h"
11 u_32_t getoptbyname(optname)
12 char *optname;
14 struct ipopt_names *io;
16 for (io = ionames; io->on_name; io++)
17 if (!strcasecmp(optname, io->on_name))
18 return io->on_bit;
19 return -1;
23 u_32_t getoptbyvalue(optval)
24 int optval;
26 struct ipopt_names *io;
28 for (io = ionames; io->on_name; io++)
29 if (io->on_value == optval)
30 return io->on_bit;
31 return -1;