Clean up old WinVNC services
We've changed the service name a couple of times for various
reasons. Make sure the old versions are removed when the new one
is registered.
diff --git a/win/winvnc/winvnc.cxx b/win/winvnc/winvnc.cxx
index ff16aac..57f9f3d 100644
--- a/win/winvnc/winvnc.cxx
+++ b/win/winvnc/winvnc.cxx
@@ -168,6 +168,11 @@
runServer = false;
int j = i;
i = argc;
+
+ // Try to clean up earlier services we've had
+ rfb::win32::unregisterService("WinVNC4");
+ rfb::win32::unregisterService("TigerVNC Server");
+
if (rfb::win32::registerService(VNCServerService::Name,
_T("TigerVNC Server"),
_T("Provides remote access to this machine via the VNC/RFB protocol."),