From eb996af851c046d040f89caedde0e28c7a7cf84d Mon Sep 17 00:00:00 2001 From: Viktor Szakats Date: Fri, 1 Dec 2023 14:44:50 +0000 Subject: [PATCH] tests: sync port number type with the rest of codebase Tested via #1257 --- tests/test_ssh2.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/test_ssh2.c b/tests/test_ssh2.c index b485e0f6..cee99230 100644 --- a/tests/test_ssh2.c +++ b/tests/test_ssh2.c @@ -25,7 +25,7 @@ #include /* for getenv() */ static const char *hostname = "127.0.0.1"; -static const unsigned short port_number = 4711; +static const int port_number = 4711; static const char *pubkey = "key_rsa.pub"; static const char *privkey = "key_rsa"; static const char *username = "username"; @@ -104,7 +104,7 @@ int main(int argc, char *argv[]) } sin.sin_family = AF_INET; - sin.sin_port = htons(port_number); + sin.sin_port = htons((unsigned short)port_number); sin.sin_addr.s_addr = hostaddr; for(counter = 0; counter < 3; ++counter) {