Fix network ports datatype (unsigned int -> unsigned short). UDPSocket: fix old bug using m_port instead of m_port[x].

This commit is contained in:
Daniel Caujolle-Bert
2021-04-25 07:51:01 +02:00
parent 7b1ba5d849
commit ee2d6fd488
23 changed files with 98 additions and 96 deletions
+2 -2
View File
@@ -35,7 +35,7 @@ int main(int argc, char** argv)
return 1;
}
unsigned int port = ::atoi(argv[1U]);
unsigned short port = (unsigned short)::atoi(argv[1U]);
if (port == 0U) {
::fprintf(stderr, "P25Parrot: invalid port number - %s\n", argv[1U]);
return 1;
@@ -47,7 +47,7 @@ int main(int argc, char** argv)
return 0;
}
CP25Parrot::CP25Parrot(unsigned int port) :
CP25Parrot::CP25Parrot(unsigned short port) :
m_port(port)
{
CUDPSocket::startup();