xrdp: get port from configfile in access_control()

This fixes #894
This commit is contained in:
Oscar Salvador 2017-09-28 08:44:00 +02:00 committed by metalefty
parent ced3a4817f
commit be23682f90

View File

@ -1471,11 +1471,13 @@ access_control(char *username, char *password, char *srv)
unsigned long size;
int index;
int socket = g_tcp_socket();
char port[8];
if (socket != -1)
{
xrdp_mm_get_sesman_port(port, sizeof(port));
/* we use a blocking socket here */
reply = g_tcp_connect(socket, srv, "3350");
reply = g_tcp_connect(socket, srv, port);
if (reply == 0)
{