* [B.A.T.M.A.N.] [PATCHv2] batman-adv: return NULL instead of 0 in batadv_mcast_forw_ip_node_get()
@ 2014-02-16 9:27 Linus Lüssing
2014-02-16 9:34 ` Marek Lindner
0 siblings, 1 reply; 2+ messages in thread
From: Linus Lüssing @ 2014-02-16 9:27 UTC (permalink / raw)
To: b.a.t.m.a.n
batadv_mcast_forw_ip_node_get() returns a pointer, so returning NULL in
error cases is always more appropriate than 0.
Introduced by: c8fedbea81eac41a4971bb43353fd52a903d7c4c
("batman-adv: Send multicast packets to nodes with a WANT_ALL flag")
Reported-by: Antonio Quartulli <antonio@meshcoding.com>
Signed-off-by: Linus Lüssing <linus.luessing@web.de>
---
* added Reported-by
multicast.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/multicast.c b/multicast.c
index b2abe00..00bb30e 100644
--- a/multicast.c
+++ b/multicast.c
@@ -498,7 +498,7 @@ batadv_mcast_forw_ip_node_get(struct batadv_priv *bat_priv,
return batadv_mcast_forw_ipv6_node_get(bat_priv);
default:
/* we shouldn't be here... */
- return 0;
+ return NULL;
}
}
--
1.7.10.4
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [B.A.T.M.A.N.] [PATCHv2] batman-adv: return NULL instead of 0 in batadv_mcast_forw_ip_node_get()
2014-02-16 9:27 [B.A.T.M.A.N.] [PATCHv2] batman-adv: return NULL instead of 0 in batadv_mcast_forw_ip_node_get() Linus Lüssing
@ 2014-02-16 9:34 ` Marek Lindner
0 siblings, 0 replies; 2+ messages in thread
From: Marek Lindner @ 2014-02-16 9:34 UTC (permalink / raw)
To: b.a.t.m.a.n
[-- Attachment #1: Type: text/plain, Size: 597 bytes --]
On Sunday 16 February 2014 10:27:58 Linus Lüssing wrote:
> batadv_mcast_forw_ip_node_get() returns a pointer, so returning NULL in
> error cases is always more appropriate than 0.
>
> Introduced by: c8fedbea81eac41a4971bb43353fd52a903d7c4c
> ("batman-adv: Send multicast packets to nodes with a WANT_ALL flag")
>
> Reported-by: Antonio Quartulli <antonio@meshcoding.com>
> Signed-off-by: Linus Lüssing <linus.luessing@web.de>
> ---
> * added Reported-by
>
> multicast.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
Applied in revision 0dd5d2c.
Thanks,
Marek
[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 490 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2014-02-16 9:34 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-02-16 9:27 [B.A.T.M.A.N.] [PATCHv2] batman-adv: return NULL instead of 0 in batadv_mcast_forw_ip_node_get() Linus Lüssing
2014-02-16 9:34 ` Marek Lindner
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox