]> git.ipfire.org Git - thirdparty/dhcpcd.git/commitdiff
Allow multiple automatic SLA if no SLA is set to 0.
authorRoy Marples <roy@marples.name>
Tue, 2 Feb 2016 22:45:15 +0000 (22:45 +0000)
committerRoy Marples <roy@marples.name>
Tue, 2 Feb 2016 22:45:15 +0000 (22:45 +0000)
if-options.c

index 0ca9f9373908cf2ea7c4199706f29996a336a09d..5330d6dc5ee62a1857385bc3933d6cdea563ac73 100644 (file)
@@ -1486,7 +1486,9 @@ parse_option(struct dhcpcd_ctx *ctx, const char *ifname, struct if_options *ifo,
                                            sla->ifname);
                                        goto err_sla;
                                }
-                               if (slap->sla == 0 || sla->sla == 0) {
+                               if (slap->sla_set &&
+                                   (slap->sla == 0 || sla->sla == 0))
+                               {
                                        logger(ctx, LOG_ERR, "%s: cannot"
                                            " assign multiple prefixes"
                                            " with a SLA of 0",