Removed some legacy stuff.
[nssm.git] / service.cpp
index a400ebd..6292698 100644 (file)
@@ -101,7 +101,7 @@ int install_service(char *name, char *exe, char *flags) {
     fprintf(stderr, "The full path to " NSSM " is too long!\n");\r
     return 3;\r
   }\r
-  if (snprintf(command, sizeof(command), "\"%s\" %s", path, NSSM_RUN) < 0) {\r
+  if (_snprintf(command, sizeof(command), "\"%s\" %s", path, NSSM_RUN) < 0) {\r
     fprintf(stderr, "Out of memory for ImagePath!\n");\r
     return 4;\r
   }\r
@@ -235,7 +235,7 @@ int monitor_service() {
   int ret = start_service();\r
   if (ret) {\r
     char code[16];\r
-    snprintf(code, sizeof(code), "%d", ret);\r
+    _snprintf(code, sizeof(code), "%d", ret);\r
     log_event(EVENTLOG_ERROR_TYPE, NSSM_EVENT_START_SERVICE_FAILED, exe, service_name, ret, 0);\r
     return ret;\r
   }\r