示例#1
0
文件: cDHCP.cs 项目: emacslisp/cs
 public void Dispose()
 {
     if (cUdp != null)
     {
         cUdp.StopListener();
     }
     cUdp = null;
 }
示例#2
0
文件: cDHCP.cs 项目: emacslisp/cs
 //function to start the DHCP server
 //port 67 to recieve, 68 to send
 public void StartDHCPServer()
 {
     try {   // start the DHCP server
         //assign the event handlers
         cUdp           = new clsUDP(67, 68, NetCard);
         cUdp.DataRcvd += new clsUDP.DataRcvdEventHandler(cUdp_DataRcvd);
     }
     catch (Exception ex) {
         Console.WriteLine(ex.Message);
     }
 }