]> git.neil.brown.name Git - history.git/commitdiff
[NETFILER/ipt_REJECT]: Use LL_RESERVED_SPACE() where applicable.
authorHideaki Yoshifuji <yoshfuji@linux-ipv6.org>
Mon, 9 Feb 2004 03:12:54 +0000 (19:12 -0800)
committerHideaki Yoshifuji <yoshfuji@linux-ipv6.org>
Mon, 9 Feb 2004 03:12:54 +0000 (19:12 -0800)
net/ipv4/netfilter/ipt_REJECT.c

index 8445b5ed7608d674121cbf91dde2c1442b231c8b..b07eb821057bda5973aea33847dd4e92b1dd566e 100644 (file)
@@ -117,7 +117,7 @@ static void send_reset(struct sk_buff *oldskb, int hook)
        if ((rt = route_reverse(oldskb, hook)) == NULL)
                return;
 
-       hh_len = (rt->u.dst.dev->hard_header_len + 15)&~15;
+       hh_len = LL_RESERVED_SPACE(rt->u.dst.dev);
 
        /* We need a linear, writeable skb.  We also need to expand
           headroom in case hh_len of incoming interface < hh_len of
@@ -305,9 +305,9 @@ static void send_unreach(struct sk_buff *skb_in, int code)
        if (length > 576)
                length = 576;
 
-       hh_len = (rt->u.dst.dev->hard_header_len + 15)&~15;
+       hh_len = LL_RESERVED_SPACE(rt->u.dst.dev);
 
-       nskb = alloc_skb(hh_len+15+length, GFP_ATOMIC);
+       nskb = alloc_skb(hh_len + length, GFP_ATOMIC);
        if (!nskb) {
                ip_rt_put(rt);
                return;