Merge branch 'mainstream'
[sliver-openvswitch.git] / tests / test-multipath.c
index f1b12e2..7a89779 100644 (file)
@@ -26,7 +26,6 @@
 
 #include "flow.h"
 #include "ofp-actions.h"
-#include "random.h"
 #include "util.h"
 
 int
@@ -39,7 +38,6 @@ main(int argc, char *argv[])
     int n;
 
     set_program_name(argv[0]);
-    random_init();
 
     if (argc != 2) {
         ovs_fatal(0, "usage: %s multipath_action", program_name);
@@ -65,9 +63,7 @@ main(int argc, char *argv[])
             struct flow_wildcards wc;
             struct flow flow;
 
-            random_bytes(&flow, sizeof flow);
-            memset(flow.zeros, 0, sizeof flow.zeros);
-            flow.mpls_depth = 0;
+            flow_random_hash_fields(&flow);
 
             mp.max_link = n - 1;
             multipath_execute(&mp, &flow, &wc);
@@ -132,7 +128,7 @@ main(int argc, char *argv[])
             break;
 
         default:
-            NOT_REACHED();
+            OVS_NOT_REACHED();
         }
     }