예제 #1
0
        public override void sceNetAdhocctlInit()
        {
            //if (log.DebugEnabled)
            {
                Console.WriteLine("sceNetAdhocctlInit");
            }

            // Wait for a previous instance of the Friend Finder thread to terminate
            waitForFriendFinderToExit();

            terminatePortManager();
            closeConnectionToMetaServer();
            connectToMetaServer();
            exit_Renamed = false;

            portManager = new PortManager(upnp);

            if (metaSocket != null)
            {
                Thread friendFinderThread = new FriendFinder(this);
                friendFinderThread.Name   = "ProOnline Friend Finder";
                friendFinderThread.Daemon = true;
                friendFinderThread.Start();
            }
        }
예제 #2
0
 /// <summary>
 /// Delete all the port/host mappings
 /// </summary>
 private void terminatePortManager()
 {
     if (portManager != null)
     {
         portManager.clear();
         portManager = null;
     }
 }