Guest User

Untitled

a guest
Jul 20th, 2018
75
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.92 KB | None | 0 0
  1. public void run()
  2.         {
  3.             //**************************************************************//
  4.             // Sit and wait until something (a web browser here)            //
  5.             // attempts to connect to us.                                   //
  6.             //                                                              //
  7.             // This is run in a seperate thread otherwise our main form     //
  8.             // will lock up and become unusable.                            //
  9.             //**************************************************************//
  10.  
  11.             Console.Out.WriteLine("Thread running");
  12.  
  13.             while (true)
  14.             {
  15.                 connection = listeningSocket.AcceptSocket();
  16.                 ConnectionThread c = new ConnectionThread(connection);
  17.                 Thread ct = new Thread(new ThreadStart(c.run));
  18.  
  19.                 ct.Start();
  20.             }
  21.         }
Add Comment
Please, Sign In to add comment