commit | bfc5c48c73d1c31081d7e679d5f5f6f4164abcce | [log] [tgz] |
---|---|---|
author | Jonathan Hart <jono@onlab.us> | Tue Apr 05 18:57:00 2016 -0700 |
committer | Gerrit Code Review <gerrit@onlab.us> | Wed Apr 06 17:42:10 2016 +0000 |
tree | dc9f0ece9f3080f7ce772952247ccd14befacd6b | |
parent | 96f689b317681203842cb63f27586a51c5b7b427 [diff] [blame] |
Implementation of the route service Change-Id: I4e905cf868ad69c426e4f4155dfd83e1f8b00335
diff --git a/incubator/api/src/main/java/org/onosproject/incubator/net/routing/Route.java b/incubator/api/src/main/java/org/onosproject/incubator/net/routing/Route.java index 857d69b..590b218 100644 --- a/incubator/api/src/main/java/org/onosproject/incubator/net/routing/Route.java +++ b/incubator/api/src/main/java/org/onosproject/incubator/net/routing/Route.java
@@ -70,8 +70,7 @@ */ public Route(Source source, IpPrefix prefix, IpAddress nextHop) { checkNotNull(prefix); - checkNotNull(nextHop); - checkArgument(prefix.version().equals(nextHop.version()), VERSION_MISMATCH); + checkArgument(nextHop == null || prefix.version().equals(nextHop.version()), VERSION_MISMATCH); this.source = checkNotNull(source); this.prefix = prefix;