소스 검색

Added random seed init.

Camilla Berglund 12 년 전
부모
커밋
f5dc6e4007
1개의 변경된 파일3개의 추가작업 그리고 0개의 파일을 삭제
  1. 3 0
      tests/reopen.c

+ 3 - 0
tests/reopen.c

@@ -35,6 +35,7 @@
 
 #include <GLFW/glfw3.h>
 
+#include <time.h>
 #include <stdio.h>
 #include <stdlib.h>
 
@@ -112,6 +113,8 @@ int main(int argc, char** argv)
     int count = 0;
     GLFWwindow* window;
 
+    srand(time(NULL));
+
     glfwSetErrorCallback(error_callback);
 
     if (!glfwInit())