From 46fb3cc1c3e7dc2a006c1546a9e3c16ac529ca16 Mon Sep 17 00:00:00 2001 From: Michael Larson Date: Tue, 16 Nov 2010 09:33:49 -0800 Subject: update call to error location api. --- scripts/system/vyatta_update_resolv.pl | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'scripts/system/vyatta_update_resolv.pl') diff --git a/scripts/system/vyatta_update_resolv.pl b/scripts/system/vyatta_update_resolv.pl index 3f0d539e..70127512 100755 --- a/scripts/system/vyatta_update_resolv.pl +++ b/scripts/system/vyatta_update_resolv.pl @@ -47,8 +47,15 @@ if ($dhclient_script == 1) { } if ($dhclient_script == 0 && @domains > 0 && $domain_name && length($domain_name) > 0) { - Vyatta::Config::outputError(["system domain-name","system domain-search domain"],"System configuration error. Both \'domain-name\' and \'domain-search\' are specified, but only one of these mutually exclusive parameters is allowed."); - exit(1); + my @loc; + if ($vc->returnOrigValues('domain-search domain') > 0) { + @loc = ["system","domain-name"]; + } + else { + @loc = ["system","domain-search","domain"]; + } + Vyatta::Config::outputError(@loc,"System configuration error. Both \'domain-name\' and \'domain-search\' are specified, but only one of these mutually exclusive parameters is allowed."); + exit(1); } my $doms = ''; -- cgit v1.2.3