diff options
author | peter <peter@FreeBSD.org> | 1998-03-21 10:04:55 +0000 |
---|---|---|
committer | peter <peter@FreeBSD.org> | 1998-03-21 10:04:55 +0000 |
commit | 58e3555d887b6a5b1f460d8ee84ca4e97c0a8217 (patch) | |
tree | b9974c621ce6d3d5054fe5cc47ebdcbc84178204 /contrib/ipfilter/parse.c | |
parent | 594e73c3109178aa1c5317785aaa284a0c135ff4 (diff) | |
download | FreeBSD-src-58e3555d887b6a5b1f460d8ee84ca4e97c0a8217.zip FreeBSD-src-58e3555d887b6a5b1f460d8ee84ca4e97c0a8217.tar.gz |
Import ipfilter 3.2.3
Diffstat (limited to 'contrib/ipfilter/parse.c')
-rw-r--r-- | contrib/ipfilter/parse.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/contrib/ipfilter/parse.c b/contrib/ipfilter/parse.c index c84205b..bbc1925 100644 --- a/contrib/ipfilter/parse.c +++ b/contrib/ipfilter/parse.c @@ -35,7 +35,7 @@ #if !defined(lint) static const char sccsid[] ="@(#)parse.c 1.44 6/5/96 (C) 1993-1996 Darren Reed"; -static const char rcsid[] = "@(#)$Id: parse.c,v 2.0.2.18 1997/10/19 15:39:29 darrenr Exp $"; +static const char rcsid[] = "@(#)$Id: parse.c,v 2.0.2.18.2.1 1997/11/20 12:43:49 darrenr Exp $"; #endif extern struct ipopt_names ionames[], secclass[]; @@ -475,7 +475,8 @@ char *line; /* * lazy users... */ - if (!fil.fr_proto && (fil.fr_dcmp || fil.fr_scmp || fil.fr_tcpf)) { + if (!fil.fr_proto && !(fil.fr_ip.fi_fl & FI_TCPUDP) && + (fil.fr_dcmp || fil.fr_scmp || fil.fr_tcpf)) { (void)fprintf(stderr, "no protocol given for TCP/UDP comparisons\n"); return NULL; @@ -541,7 +542,7 @@ u_char *cp; /* * is it possibly hostname/num ? */ - if ((s = index(**seg, '/'))) { + if ((s = index(**seg, '/')) || (s = index(**seg, ':'))) { *s++ = '\0'; if (!isdigit(*s)) return -1; |