Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ebc8af71 authored by Lorenzo Colitti's avatar Lorenzo Colitti
Browse files

Allow 0.0.0.0 and :: as default gateways

On point-to-point interfaces, some RILs return the unspecified
address (0.0.0.0 or ::) as the gateway. This is correct, as
routes pointing at point-to-point interfaces don't need
gateways. Currently, telephony ignores these routes, causing
loss of connectivity (for example, when using an IPv6 APN on
Galaxy Nexus). Allow these routes to be set.

Bug: 8475171
Bug: 8276725
Change-Id: I3a770628c9717bb6e451a523417401b56ba55763
parent 4e9ed041
Loading
Loading
Loading
Loading
+2 −3
Original line number Diff line number Diff line
@@ -211,10 +211,9 @@ public class DataCallResponse {
                    } catch (IllegalArgumentException e) {
                        throw new UnknownHostException("Non-numeric gateway addr=" + addr);
                    }
                    if (! ia.isAnyLocalAddress()) {
                    // Allow 0.0.0.0 or :: as a gateway; this indicates a point-to-point interface.
                    linkProperties.addRoute(new RouteInfo(ia));
                }
                }

                result = SetupResult.SUCCESS;
            } catch (UnknownHostException e) {