diff options
author | Ansis Atteka <aatteka@nicira.com> | 2013-09-18 18:29:52 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2013-09-19 14:11:15 -0400 |
commit | 749154aa56b57652a282cbde57a57abc278d1205 (patch) | |
tree | acf1977fa73c95547c0c121ef13c6e1fc1d4e8ef /net | |
parent | 279f438e36c0a70b23b86d2090aeec50155034a9 (diff) |
ip: use ip_hdr() in __ip_make_skb() to retrieve IP header
skb->data already points to IP header, but for the sake of
consistency we can also use ip_hdr() to retrieve it.
Signed-off-by: Ansis Atteka <aatteka@nicira.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net')
-rw-r--r-- | net/ipv4/ip_output.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/ipv4/ip_output.c b/net/ipv4/ip_output.c index 9ee17e3d11c3..eae2e262fbe5 100644 --- a/net/ipv4/ip_output.c +++ b/net/ipv4/ip_output.c | |||
@@ -1316,7 +1316,7 @@ struct sk_buff *__ip_make_skb(struct sock *sk, | |||
1316 | else | 1316 | else |
1317 | ttl = ip_select_ttl(inet, &rt->dst); | 1317 | ttl = ip_select_ttl(inet, &rt->dst); |
1318 | 1318 | ||
1319 | iph = (struct iphdr *)skb->data; | 1319 | iph = ip_hdr(skb); |
1320 | iph->version = 4; | 1320 | iph->version = 4; |
1321 | iph->ihl = 5; | 1321 | iph->ihl = 5; |
1322 | iph->tos = inet->tos; | 1322 | iph->tos = inet->tos; |