4 * Copyright (C) 2002 by Darren Reed.
6 * See the IPFILTER.LICENCE file for details on licencing.
8 * $Id: nametokva.c,v 1.1.4.1 2006/06/16 17:21:07 darrenr Exp $
13 #include <sys/ioctl.h>
16 ipfunc_t nametokva(name, iocfunc)
23 strncpy(res.ipfu_name, name, sizeof(res.ipfu_name));
27 if ((opts & OPT_DONOTHING) == 0) {
28 fd = open(IPL_NAME, O_RDONLY);
32 (void) (*iocfunc)(fd, SIOCFUNCL, &res);
35 if (res.ipfu_addr == NULL)
36 res.ipfu_addr = (ipfunc_t)-1;