Signed-off-by: Ciprian Barbu <[email protected]>
---
The source was not initialized before calling ofpbuf_init__, which is needed by
the ODP netdev implementation.

 lib/ofpbuf.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/lib/ofpbuf.c b/lib/ofpbuf.c
index 764a799..6f27b47 100644
--- a/lib/ofpbuf.c
+++ b/lib/ofpbuf.c
@@ -38,11 +38,11 @@ static void
 ofpbuf_use__(struct ofpbuf *b, void *base, size_t allocated,
              enum ofpbuf_source source)
 {
+    ofpbuf_init__(b, allocated, source);
+
     ofpbuf_set_base(b, base);
     ofpbuf_set_data(b, base);
     ofpbuf_set_size(b, 0);
-
-    ofpbuf_init__(b, allocated, source);
 }
 
 /* Initializes 'b' as an empty ofpbuf that contains the 'allocated' bytes of
-- 
1.8.3.2


_______________________________________________
lng-odp mailing list
[email protected]
http://lists.linaro.org/mailman/listinfo/lng-odp

Reply via email to