]> git.ipfire.org Git - thirdparty/bird.git/commitdiff
Birdtest: move def bt_rand_num() at a better place
authorPavel Tvrdík <pawel.tvrdik@gmail.cz>
Fri, 3 Apr 2015 10:44:47 +0000 (12:44 +0200)
committerPavel Tvrdík <pawel.tvrdik@gmail.cz>
Fri, 3 Apr 2015 10:44:47 +0000 (12:44 +0200)
test/birdtest.c

index 0047142510cdfdfdb9fb673c071a5d30794265ba..3b9617cec198660e758449c306d22773c46c974e 100644 (file)
@@ -28,6 +28,13 @@ int bt_verbose;
 const char *bt_filename;
 const char *bt_test_id;
 
+int
+bt_rand_num(void)
+{
+  /* Seeded in bt_init() */
+  return random();
+}
+
 void
 bt_init(int argc, char *argv[])
 {
@@ -175,8 +182,3 @@ bt_test_case5(int (*test_fn)(void), const char *test_id, const char *dsc, int fo
   bt_note("OK");
 }
 
-int
-bt_rand_num(void)
-{
-  return random();
-}