OSDN Git Service
(root)
/
android-x86
/
kernel.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
08ad76e
)
batman-adv: get rid of pointless cast in memcpy()
author
Al Viro
<viro@ZenIV.linux.org.uk>
Sun, 22 Apr 2012 06:50:29 +0000
(07:50 +0100)
committer
Antonio Quartulli
<ordex@autistici.org>
Mon, 18 Jun 2012 16:01:01 +0000
(18:01 +0200)
memcpy() arguments are void *, precisely to avoid that kind of pointless
casts.
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Sven Eckelmann <sven@narfation.org>
net/batman-adv/bridge_loop_avoidance.c
patch
|
blob
|
history
diff --git
a/net/batman-adv/bridge_loop_avoidance.c
b/net/batman-adv/bridge_loop_avoidance.c
index
5c1ac55
..
89e2b1c
100644
(file)
--- a/
net/batman-adv/bridge_loop_avoidance.c
+++ b/
net/batman-adv/bridge_loop_avoidance.c
@@
-510,7
+510,7
@@
static void bla_send_announce(struct bat_priv *bat_priv,
memcpy(mac, announce_mac, 4);
crc = htons(backbone_gw->crc);
- memcpy(&mac[4],
(uint8_t *)
&crc, 2);
+ memcpy(&mac[4], &crc, 2);
bla_send_claim(bat_priv, mac, backbone_gw->vid, CLAIM_TYPE_ANNOUNCE);