ofproto: Correctly compute length of flow stats in multipart flow stats.
[openvswitch] / ofproto / ofproto.c
index e081e32e96c2a3c6f2bfbf34774cb106879a2be0..7df8600e54b853c9c8859b691b7968440147bfe7 100644 (file)
@@ -3549,8 +3549,8 @@ put_nx_flow_stats(struct ofconn *ofconn, struct rule *rule,
 
     act_len = sizeof *rule->actions * rule->n_actions;
 
-    start_len = (*replyp)->size;
     append_nxstats_reply(sizeof *nfs + NXM_MAX_LEN + act_len, ofconn, replyp);
+    start_len = (*replyp)->size;
     reply = *replyp;
 
     nfs = ofpbuf_put_uninit(reply, sizeof *nfs);