Ah, I see the out_of_memory code.. I'd resend without the NULL checks (with just the conversion to xzalloc).

---
Nuage Networks Business Unit, Alcatel-Lucent,
755 Ravendale Drive, Mountain View, CA, 94043
Mailstop: 1127, Ph: 1-650-623-3461

On Fri, 5 Jun 2015, Ben Pfaff wrote:

On Fri, Jun 05, 2015 at 10:48:30AM -0700, Sabyasachi Sengupta wrote:

Use xzalloc instead of xmalloc for some key structure allocations in
ofproto-dpif (viz. ofproto_dpif, ofport_dpif and rule_dpif) so as to
prevent uninitialized values in these structures. Also add seat belts
around these structure allocations.

Signed-off-by: Sabyasachi Sengupta <sabyasachi.sengu...@alcatel-lucent.com>

It makes no sense to check the xmalloc() or xzalloc() return value for
NULL.

_______________________________________________
dev mailing list
dev@openvswitch.org
http://openvswitch.org/mailman/listinfo/dev

Reply via email to