]> git.ipfire.org Git - thirdparty/tor.git/commitdiff
Forward-port fix to make dual-purpose NT executable work.
authorNick Mathewson <nickm@torproject.org>
Wed, 23 Feb 2005 05:34:25 +0000 (05:34 +0000)
committerNick Mathewson <nickm@torproject.org>
Wed, 23 Feb 2005 05:34:25 +0000 (05:34 +0000)
svn:r3665

src/or/main.c

index 6ac83e1728469e40a4ed4ad5007e2d8309365099..74b7b7dcdad9a1b3d36926f1fc121b04bc07c5ea 100644 (file)
@@ -1645,11 +1645,14 @@ int tor_main(int argc, char *argv[]) {
     nt_service_main();
     return 0;
   }
-#else
+#endif
   if (tor_init(argc, argv)<0)
     return -1;
   switch (get_options()->command) {
   case CMD_RUN_TOR:
+#ifdef MS_WINDOWS_SERVICE 
+    service_status.dwCurrentState = SERVICE_RUNNING;
+#endif
     do_main_loop();
     break;
   case CMD_LIST_FINGERPRINT:
@@ -1664,6 +1667,5 @@ int tor_main(int argc, char *argv[]) {
   }
   tor_cleanup();
   return -1;
-#endif
 }