batman-adv: Modifing hna_local_fill_buffer() return value

Message ID 1292896989-23680-1-git-send-email-ordex@ritirata.org (mailing list archive)
State Accepted, archived
Commit 06738bfffeba54435d88a002cb75004101d07492
Headers

Commit Message

Antonio Quartulli Dec. 21, 2010, 2:03 a.m. UTC
  After changeset 1888, the return value of hna_local_fill_buffer() has
 not been changed to _count_. In this way an eroneous num_hna was
 calculated before sending the new OGM packet.

---
 translation-table.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
  

Comments

Marek Lindner Dec. 21, 2010, 2:17 a.m. UTC | #1
On Tuesday 21 December 2010 03:03:09 Antonio Quartulli wrote:
>  After changeset 1888, the return value of hna_local_fill_buffer() has
>  not been changed to _count_. In this way an eroneous num_hna was
>  calculated before sending the new OGM packe

Thanks for resending the patch - applied in revision 1898.

Good catch,
Marek
  

Patch

diff --git a/translation-table.c b/translation-table.c
index a19e16c..a633b5a 100644
--- a/translation-table.c
+++ b/translation-table.c
@@ -162,7 +162,7 @@  int hna_local_fill_buffer(struct bat_priv *bat_priv,
 		atomic_set(&bat_priv->hna_local_changed, 0);
 
 	spin_unlock_bh(&bat_priv->hna_lhash_lock);
-	return i;
+	return count;
 }
 
 int hna_local_seq_print_text(struct seq_file *seq, void *offset)