]> git.sesse.net Git - rdpsrv/blobdiff - rdpsrv.c
Check return value of mcs_recv_connect_initial().
[rdpsrv] / rdpsrv.c
index 86235ec2544d0dd1fb76e7cb8ee786fb8634892c..c5b4169403f7ef271fa7f237e52257bae1925f28 100644 (file)
--- a/rdpsrv.c
+++ b/rdpsrv.c
@@ -61,10 +61,16 @@ int create_server_socket()
 
 int serve_client()
 {
+       if (!mcs_recv_connect_initial())
+               error("MCS_CONNECT_INITIAL recv failed");
+       mcs_send_connect_response();
+       
        for ( ;; ) {
                short channel;
                
                /* receive ISO packets */
                mcs_recv(&channel);
+
+               printf("Packet on ch %u\n", channel);
        }
 }