diff --git a/MailServer/Program.cs b/MailServer/Program.cs index 400d8b2..eae9705 100644 --- a/MailServer/Program.cs +++ b/MailServer/Program.cs @@ -4,6 +4,8 @@ using System.Linq; using System.ServiceProcess; using System.Text; +using MailServer.Services; + namespace MailServer { static class Program @@ -22,7 +24,7 @@ namespace MailServer ServiceBase[] ServicesToRun; ServicesToRun = new ServiceBase[] { - new IMAP_s() + new IMAP_Service() }; ServiceBase.Run(ServicesToRun); /* diff --git a/MailServer/IMAP_s.Designer.cs b/MailServer/Services/IMAP/Server/IMAP_Service.Designer.cs similarity index 91% rename from MailServer/IMAP_s.Designer.cs rename to MailServer/Services/IMAP/Server/IMAP_Service.Designer.cs index bac1539..0e99194 100644 --- a/MailServer/IMAP_s.Designer.cs +++ b/MailServer/Services/IMAP/Server/IMAP_Service.Designer.cs @@ -1,8 +1,8 @@ using MailServer.IMAP.Server; -namespace MailServer +namespace MailServer.Services { - partial class IMAP_s + partial class IMAP_Service { /// /// Erforderliche Designervariable. diff --git a/MailServer/IMAP_s.cs b/MailServer/Services/IMAP/Server/IMAP_Service.cs similarity index 92% rename from MailServer/IMAP_s.cs rename to MailServer/Services/IMAP/Server/IMAP_Service.cs index b2b5503..43189ce 100644 --- a/MailServer/IMAP_s.cs +++ b/MailServer/Services/IMAP/Server/IMAP_Service.cs @@ -9,13 +9,13 @@ using System.Text; using MailServer.IMAP.Server; -namespace MailServer +namespace MailServer.Services { - public partial class IMAP_s : ServiceBase + public partial class IMAP_Service : ServiceBase { private IMAP_Server server; - public IMAP_s() + public IMAP_Service() { InitializeComponent(); putEvents(); @@ -55,6 +55,7 @@ namespace MailServer protected override void OnStop() { + this.server.StopServer(); } } }