Blog |Follow Nick on Twitter| About
 

I've received a patch from ed.davison, if you have commented out hosts in your config, you'll get odd \"address - hostname\" results in the drop down list. Ed's patch fixes that; thankx :-D

At the moment you'd have to apply the patch your self from the below; but I have a official revision in the pipeline.

-- readhosts.php 2005/11/09 18:07:43 1.1 +++ readhosts.php 2005/11/09 18:08:12 @@ -23,16 +23,20 @@ $current = trim($line); - if (preg_match (\"/addres/\", \"$current\")) { - $keywords = preg_split (\"/[\\s,]+/\", \"$current\"); - $ipaddress[$counter] = $keywords[1]; - $counter++; - } - - if (preg_match (\"/host_name/\", \"$current\")) { - $keywords = preg_split (\"/[\\s,]+/\", \"$current\"); - $node_name[$counter2] = $keywords[1]; - $counter2++; + if (!preg_match (\"/^#/\", \"$current\")) { + + if (preg_match (\"/addres/\", \"$current\")) { + $keywords = preg_split (\"/[\\s,]+/\", \"$current\"); + $ipaddress[$counter] = $keywords[1]; + $counter++; + } + + if (preg_match (\"/host_name/\", \"$current\")) { + $keywords = preg_split (\"/[\\s,]+/\", \"$current\"); + $node_name[$counter2] = $keywords[1]; + $counter2++; + } + }

 

 
Nick Bettison ©