From bee73adc5bd2e9c66339fb969a9b5ad85d8f9009 Mon Sep 17 00:00:00 2001 From: Armin Novak Date: Fri, 17 Feb 2017 10:59:22 +0100 Subject: [PATCH] Replaced random() with winpr_RAND --- libfreerdp/core/test/TestConnect.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/libfreerdp/core/test/TestConnect.c b/libfreerdp/core/test/TestConnect.c index cd2b01847..3a109052a 100644 --- a/libfreerdp/core/test/TestConnect.c +++ b/libfreerdp/core/test/TestConnect.c @@ -1,5 +1,6 @@ #include #include +#include #include #include @@ -275,7 +276,9 @@ static int testSuccess(int port) int TestConnect(int argc, char* argv[]) { int randomPort; - randomPort = 3389 + (random() % 200); + int random; + winpr_RAND((BYTE*)&random, sizeof(random)); + randomPort = 3389 + (random % 200); /* Test connect to not existing server, * check if timeout is honored. */