diff options
author | Arnaldo Carvalho de Melo <acme@ghostprotocols.net> | 2007-03-31 10:55:19 -0400 |
---|---|---|
committer | David S. Miller <davem@sunset.davemloft.net> | 2007-04-26 01:28:29 -0400 |
commit | 27d7ff46a3498d3debc6ba68fb8014c702b81170 (patch) | |
tree | b5a0c617cf8339524d3b1f1633e08eae7b94cf86 /net/core/skbuff.c | |
parent | 3dbad80ac7632f243b824d469301abb97ec634a1 (diff) |
[SK_BUFF]: Introduce skb_copy_to_linear_data{_offset}
To clearly state the intent of copying to linear sk_buffs, _offset being a
overly long variant but interesting for the sake of saving some bytes.
Signed-off-by: Arnaldo Carvalho de Melo <acme@ghostprotocols.net>
Diffstat (limited to 'net/core/skbuff.c')
-rw-r--r-- | net/core/skbuff.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/core/skbuff.c b/net/core/skbuff.c index 17c6bb5927b6..331d3efa82fa 100644 --- a/net/core/skbuff.c +++ b/net/core/skbuff.c | |||
@@ -1129,7 +1129,7 @@ int skb_store_bits(const struct sk_buff *skb, int offset, void *from, int len) | |||
1129 | if ((copy = start - offset) > 0) { | 1129 | if ((copy = start - offset) > 0) { |
1130 | if (copy > len) | 1130 | if (copy > len) |
1131 | copy = len; | 1131 | copy = len; |
1132 | memcpy(skb->data + offset, from, copy); | 1132 | skb_copy_to_linear_data_offset(skb, offset, from, copy); |
1133 | if ((len -= copy) == 0) | 1133 | if ((len -= copy) == 0) |
1134 | return 0; | 1134 | return 0; |
1135 | offset += copy; | 1135 | offset += copy; |