Index: html/includes/print/port.inc.php =================================================================== --- html/includes/print/port.inc.php (revision 6918) +++ html/includes/print/port.inc.php (working copy) @@ -374,19 +374,22 @@ foreach ($int_links as $int_link) { $link_if = get_port_by_id_cache($int_link); - $link_dev = device_by_id_cache($link_if['device_id']); - echo($br); + if (device_permitted($link_if['device_id'])) + { + $link_dev = device_by_id_cache($link_if['device_id']); + echo($br); - if ($int_links_phys[$int_link]) { echo(' '); } - else { echo(' '); } + if ($int_links_phys[$int_link]) { echo(' '); } + else { echo(' '); } - echo("" . generate_port_link($link_if, $link_if['port_label_short']) . " on " . generate_device_link($link_dev, short_hostname($link_dev['hostname'])) . ""); + echo("" . generate_port_link($link_if, $link_if['port_label_short']) . " on " . generate_device_link($link_dev, short_hostname($link_dev['hostname'])) . ""); - ## FIXME -- do something fancy here. + ## FIXME -- do something fancy here. - if ($int_links_v6[$int_link]) { echo ' ', overlib_link('', 'IPv6', implode("
", $int_links_v6[$int_link]), NULL); } - if ($int_links_v4[$int_link]) { echo ' ', overlib_link('', 'IPv4', implode("
", $int_links_v4[$int_link]), NULL); } - $br = "
"; + if ($int_links_v6[$int_link]) { echo ' ', overlib_link('', 'IPv6', implode("
", $int_links_v6[$int_link]), NULL); } + if ($int_links_v4[$int_link]) { echo ' ', overlib_link('', 'IPv4', implode("
", $int_links_v4[$int_link]), NULL); } + $br = "
"; + } } // Output content of unknown links array (where ports don't exist in our database, or they weren't matched)