Project

General

Profile

« Previous | Next » 

Revision ca96864b

Added by Seth Mos over 16 years ago

Correctly process static gateway entries which have a label and not a IP.

View differences:

etc/inc/gwlb.inc
226 226
		if(interface_has_gateway($ifname)) {
227 227
			$gateway = array();
228 228
			$friendly = convert_real_interface_to_friendly_interface_name($ifname);
229
			$gateway['gateway'] = get_interface_gateway($ifname);
229
			if(isset($config['interfaces'][$friendly]['gateway'])) {
230
				$gateway['gateway'] = lookup_gateway_ip_by_name($config['interfaces'][$friendly]['gateway']);
231
			} else {
232
				$gateway['gateway'] = get_interface_gateway($ifname);
233
			}
230 234
			/* Loopback for dynamic interfaces without a IP */
231 235
			if(!is_ipaddr($gateway['gateway'])) {
232 236
				 $gateway['gateway'] = "127.0.0.2";

Also available in: Unified diff