]> git.droids-corp.org - dpdk.git/commitdiff
ip_frag: replace hardcoded value with a macro
authorAnatoly Burakov <anatoly.burakov@intel.com>
Wed, 18 Jun 2014 14:50:32 +0000 (15:50 +0100)
committerThomas Monjalon <thomas.monjalon@6wind.com>
Thu, 26 Jun 2014 20:50:39 +0000 (22:50 +0200)
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Thomas Monjalon <thomas.monjalon@6wind.com>
lib/librte_ip_frag/ip_frag_internal.c

index 219221f2088e54df1a25a390098b1127bf942716..6203740a378dbd89b74e7fd4d0507cfff12b5506 100644 (file)
@@ -350,7 +350,7 @@ ip_frag_lookup(struct rte_ip_frag_tbl *tbl,
                return (tbl->last);
 
        /* different hashing methods for IPv4 and IPv6 */
-       if (key->key_len == 1)
+       if (key->key_len == IPV4_KEYLEN)
                ipv4_frag_hash(key, &sig1, &sig2);
        else
                ipv6_frag_hash(key, &sig1, &sig2);