Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 300804
b: refs/heads/master
c: d7d32ec
h: refs/heads/master
v: v3
  • Loading branch information
Marek Lindner authored and Antonio Quartulli committed Apr 18, 2012
1 parent 4e78ff0 commit e4b570a
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: c2aca02235c014de57b03aa725d9b094f7a87cac
refs/heads/master: d7d32ec0f199cc00a43434cdd920338763fab2e0
5 changes: 5 additions & 0 deletions trunk/net/batman-adv/bat_iv_ogm.c
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,11 @@
static void bat_iv_ogm_iface_enable(struct hard_iface *hard_iface)
{
struct batman_ogm_packet *batman_ogm_packet;
uint32_t random_seqno;

/* randomize initial seqno to avoid collision */
get_random_bytes(&random_seqno, sizeof(random_seqno));
atomic_set(&hard_iface->seqno, random_seqno);

hard_iface->packet_len = BATMAN_OGM_LEN;
hard_iface->packet_buff = kmalloc(hard_iface->packet_len, GFP_ATOMIC);
Expand Down

0 comments on commit e4b570a

Please sign in to comment.