From c7f1423f2e75c75b63b077212934f556af7242f2 Mon Sep 17 00:00:00 2001 From: Adam Thorn <alt36@cam.ac.uk> Date: Wed, 10 Jun 2020 17:27:58 +0100 Subject: [PATCH] Slight code tidyup --- WpkgInstaller/WpkgInstaller.cs | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/WpkgInstaller/WpkgInstaller.cs b/WpkgInstaller/WpkgInstaller.cs index 2493a87..9dcd74f 100755 --- a/WpkgInstaller/WpkgInstaller.cs +++ b/WpkgInstaller/WpkgInstaller.cs @@ -59,10 +59,10 @@ namespace WpkgInstaller dwCurrentState = ServiceState.SERVICE_START_PENDING, dwWaitHint = 100000 }; - SetServiceStatus(this.ServiceHandle, ref serviceStatus); + SetServiceStatus(ServiceHandle, ref serviceStatus); serviceStatus.dwCurrentState = ServiceState.SERVICE_RUNNING; - SetServiceStatus(this.ServiceHandle, ref serviceStatus); + SetServiceStatus(ServiceHandle, ref serviceStatus); eventLog.WriteEntry("Service started", EventLogEntryType.Information); } @@ -74,10 +74,10 @@ namespace WpkgInstaller dwCurrentState = ServiceState.SERVICE_STOP_PENDING, dwWaitHint = 100000 }; - SetServiceStatus(this.ServiceHandle, ref serviceStatus); + SetServiceStatus(ServiceHandle, ref serviceStatus); serviceStatus.dwCurrentState = ServiceState.SERVICE_STOPPED; - SetServiceStatus(this.ServiceHandle, ref serviceStatus); + SetServiceStatus(ServiceHandle, ref serviceStatus); eventLog.WriteEntry("Service stopped", EventLogEntryType.Information); } @@ -94,7 +94,7 @@ namespace WpkgInstaller RedirectStandardInput = true, RedirectStandardOutput = true, RedirectStandardError = true, - WindowStyle = System.Diagnostics.ProcessWindowStyle.Hidden, + WindowStyle = ProcessWindowStyle.Hidden, FileName = Environment.GetEnvironmentVariable("comspec"), Arguments = "/C \\\\wpkg.ch.cam.ac.uk\\wpkg\\wpkg.cmd /synchronize", @@ -132,7 +132,7 @@ namespace WpkgInstaller } - private void eventLog_EntryWritten(object sender, System.Diagnostics.EntryWrittenEventArgs e) + private void eventLog_EntryWritten(object sender, EntryWrittenEventArgs e) { } -- GitLab