X-Git-Url: https://git.sesse.net/?p=rdpsrv;a=blobdiff_plain;f=secure.c;h=56c8bef117fba0929c4d2c3e129adfaf8be2bc44;hp=62e59a526a8749e5354b6a6e4e64d66231b2ef27;hb=99f2e8c32508ab193c1d42221c86cb7fca4be9ab;hpb=baeaf1330ff12ff44eeb191b85430e3657ddb7ab diff --git a/secure.c b/secure.c index 62e59a5..56c8bef 100644 --- a/secure.c +++ b/secure.c @@ -842,7 +842,7 @@ sec_recv(void) uint16 channel; STREAM s; - while ((s = mcs_recv(&channel)) != NULL) + if ((s = mcs_recv(&channel)) != NULL) { if (/*g_encryption || !g_licence_issued*/ 1) { @@ -883,7 +883,7 @@ sec_recv(void) } } - continue; + return NULL; } if (sec_flags & SEC_LOGON_INFO) @@ -901,7 +901,7 @@ sec_recv(void) sec_send(s, SEC_LICENCE_NEG); } - continue; + return NULL; } if (sec_flags & SEC_CLIENT_RANDOM) { @@ -934,7 +934,7 @@ sec_recv(void) // now we can generate the keys sec_generate_keys(inr + SEC_RANDOM_SIZE, cacert, 1); - continue; + return NULL; } } @@ -942,7 +942,7 @@ sec_recv(void) if (channel != MCS_GLOBAL_CHANNEL) { channel_process(s, channel); - continue; + return NULL; } return s;