# 
# Copyright(C) 1996, 1997 Network Flight Recorder, Inc. 
# All rights reserved. 
#       
# Use and distribution of this software and its source code 
# are governed by the terms and conditions of the 
# Network Flight Recorder Software License ("LICENSE.TXT") 
# 
 

web_server_list = listadd( x, [ 1.2.3.4, 80 ] , [ 4.3.2.1, 81 ] ,
                [ 9.8.7.6, 9999 ] );

func our_web_server
    {
    $y = listadd ( $notused, $1, $2 );
    foreach $n inside ( web_server_list )
	    if ( $y == $n )
		    return 1;
    return 0;
    }

func doit
    {
    echo("testing ",$1," ",$2,"\n");
    if ( our_web_server ( $1, $2 ) )
	    echo($1," ",$2," is ours\n");
    else
	    echo($1," ",$2," is not ours\n");
    }


doit(1.2.3.4,80);
doit(4.3.2.1,81);
doit(9.8.7.6,9999);

doit(4.3.2.1,80);
doit(4.3.2.1,9999);
doit(10.0.0.1,80);
