Ignore:
Timestamp:
Jan 17, 2011, 11:37:46 AM (11 years ago)
Author:
kopal
Message:
  • multiple connections to the p2p network are now avoided
  • some design changes
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/CrypP2P/Internal/ConnectionManager.cs

    r2348 r2358  
    102102                disconnected = false;
    103103                lastConnectionAttempt = DateTime.Now;
    104 
    105                 try
    106                 {
    107                     if (CertificateServices.GetPeerCertificateByAvatar(Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData), "PeersAtPlay" + Path.DirectorySeparatorChar + "Certificates" + Path.DirectorySeparatorChar),
    108                         P2PSettings.Default.PeerName, P2PSettings.Default.Password) == null)
    109                     {
    110                         P2PManager.GuiLogMessage("Cannot connect, account \"" + P2PSettings.Default.PeerName + "\" not found!",
    111                                                  NotificationLevel.Warning);
    112                         return;
    113                     }
    114                 }
    115                 catch (Exception ex)
    116                 {
    117                     P2PManager.GuiLogMessage("Cannot connect using account \"" + P2PSettings.Default.PeerName + "\": " + (ex.InnerException != null ? ex.InnerException.Message : ex.Message),
    118                                                  NotificationLevel.Warning);
    119                     return;
    120                 }
    121 
     104               
    122105                if (p2PBase.IsConnected || IsConnecting)
    123106                {
Note: See TracChangeset for help on using the changeset viewer.