]> git.ipfire.org Git - thirdparty/dhcpcd.git/commitdiff
Allow ia_pd 1 eth2//64
authorRoy Marples <roy@marples.name>
Tue, 4 Jun 2013 10:42:16 +0000 (10:42 +0000)
committerRoy Marples <roy@marples.name>
Tue, 4 Jun 2013 10:42:16 +0000 (10:42 +0000)
if-options.c

index 69a5a45c0619b6393833ef3853d875ee5211e654..c9f56ad5fe43639c422866c1f36d91c2cebeba25 100644 (file)
@@ -1033,11 +1033,15 @@ got_iaid:
                                np = strchr(p, '/');
                                if (np)
                                        *np++ = '\0';
-                               errno = 0;
-                               sla->sla = atoint(p);
-                               sla->sla_set = 1;
-                               if (errno)
-                                       return -1;
+                               if (*p == '\0')
+                                       sla->sla_set = 0;
+                               else {
+                                       errno = 0;
+                                       sla->sla = atoint(p);
+                                       sla->sla_set = 1;
+                                       if (errno)
+                                               return -1;
+                               }
                                if (np) {
                                        sla->prefix_len = atoint(np);
                                        if (sla->prefix_len < 0 ||