mirror of https://github.com/toreanderson/clatd
Move plat-fallback-prefix logic into get_plat_prefix()
Feature introduced in 8aa8bfa was defective from day one, it seems.
Fixes #39
This commit is contained in:
parent
04062b282d
commit
3ea303b521
4
clatd
4
clatd
|
|
@ -374,6 +374,9 @@ sub get_plat_prefix {
|
|||
}
|
||||
if(@prefixes) {
|
||||
return $prefixes[0];
|
||||
} elsif($CFG{"plat-fallback-prefix"}) {
|
||||
p("No PLAT prefix could be discovered, using fallback");
|
||||
return $CFG{"plat-fallback-prefix"};
|
||||
} else {
|
||||
p("No PLAT prefix could be discovered. Your ISP probably doesn't provide",
|
||||
" NAT64/DNS64 PLAT service. Exiting.");
|
||||
|
|
@ -735,7 +738,6 @@ p("Starting clatd v$VERSION by Tore Anderson <tore\@fud.no>");
|
|||
# Step 1: Fill in any essential blanks in the configuration by auto-detecting
|
||||
# any missing values.
|
||||
$CFG{"plat-prefix"} ||= get_plat_prefix();
|
||||
$CFG{"plat-prefix"} ||= $CFG{"plat-fallback-prefix"};
|
||||
if(!$CFG{"plat-prefix"}) {
|
||||
w("No PLAT prefix was discovered or specified; 464XLAT cannot work.");
|
||||
exit 0;
|
||||
|
|
|
|||
Loading…
Reference in New Issue