Commit 13eac409 authored by Alexandre Julliard's avatar Alexandre Julliard

schtasks: Build with msvcrt.

parent a0863ce2
MODULE = schtasks.exe MODULE = schtasks.exe
APPMODE = -mconsole -municode
IMPORTS = oleaut32 ole32 IMPORTS = oleaut32 ole32
EXTRADLLFLAGS = -mconsole -municode -mno-cygwin
C_SRCS = \ C_SRCS = \
schtasks.c schtasks.c
...@@ -22,7 +22,6 @@ ...@@ -22,7 +22,6 @@
#include "taskschd.h" #include "taskschd.h"
#include "wine/debug.h" #include "wine/debug.h"
#include "wine/unicode.h"
WINE_DEFAULT_DEBUG_CHANNEL(schtasks); WINE_DEFAULT_DEBUG_CHANNEL(schtasks);
...@@ -141,7 +140,7 @@ static int change_command(int argc, WCHAR *argv[]) ...@@ -141,7 +140,7 @@ static int change_command(int argc, WCHAR *argv[])
HRESULT hres; HRESULT hres;
while (argc) { while (argc) {
if(!strcmpiW(argv[0], tn_optW)) { if(!wcsicmp(argv[0], tn_optW)) {
if (argc < 2) { if (argc < 2) {
FIXME("Missing /tn value\n"); FIXME("Missing /tn value\n");
return 1; return 1;
...@@ -155,12 +154,12 @@ static int change_command(int argc, WCHAR *argv[]) ...@@ -155,12 +154,12 @@ static int change_command(int argc, WCHAR *argv[])
task_name = argv[1]; task_name = argv[1];
argc -= 2; argc -= 2;
argv += 2; argv += 2;
}else if (!strcmpiW(argv[0], enable_optW)) { }else if (!wcsicmp(argv[0], enable_optW)) {
enable = TRUE; enable = TRUE;
have_option = TRUE; have_option = TRUE;
argc--; argc--;
argv++; argv++;
}else if (!strcmpiW(argv[0], tr_optW)) { }else if (!wcsicmp(argv[0], tr_optW)) {
if (argc < 2) { if (argc < 2) {
FIXME("Missing /tr value\n"); FIXME("Missing /tr value\n");
return 1; return 1;
...@@ -214,7 +213,7 @@ static int create_command(int argc, WCHAR *argv[]) ...@@ -214,7 +213,7 @@ static int create_command(int argc, WCHAR *argv[])
HRESULT hres; HRESULT hres;
while (argc) { while (argc) {
if (!strcmpiW(argv[0], xml_optW)) { if (!wcsicmp(argv[0], xml_optW)) {
if (argc < 2) { if (argc < 2) {
FIXME("Missing /xml value\n"); FIXME("Missing /xml value\n");
return 1; return 1;
...@@ -228,7 +227,7 @@ static int create_command(int argc, WCHAR *argv[]) ...@@ -228,7 +227,7 @@ static int create_command(int argc, WCHAR *argv[])
xml_file = argv[1]; xml_file = argv[1];
argc -= 2; argc -= 2;
argv += 2; argv += 2;
}else if(!strcmpiW(argv[0], tn_optW)) { }else if(!wcsicmp(argv[0], tn_optW)) {
if (argc < 2) { if (argc < 2) {
FIXME("Missing /tn value\n"); FIXME("Missing /tn value\n");
return 1; return 1;
...@@ -242,11 +241,11 @@ static int create_command(int argc, WCHAR *argv[]) ...@@ -242,11 +241,11 @@ static int create_command(int argc, WCHAR *argv[])
task_name = argv[1]; task_name = argv[1];
argc -= 2; argc -= 2;
argv += 2; argv += 2;
}else if(!strcmpiW(argv[0], f_optW)) { }else if(!wcsicmp(argv[0], f_optW)) {
flags = TASK_CREATE_OR_UPDATE; flags = TASK_CREATE_OR_UPDATE;
argc--; argc--;
argv++; argv++;
}else if (!strcmpiW(argv[0], ru_optW)) { }else if (!wcsicmp(argv[0], ru_optW)) {
if (argc < 2) { if (argc < 2) {
FIXME("Missing /ru value\n"); FIXME("Missing /ru value\n");
return 1; return 1;
...@@ -303,11 +302,11 @@ static int delete_command(int argc, WCHAR *argv[]) ...@@ -303,11 +302,11 @@ static int delete_command(int argc, WCHAR *argv[])
HRESULT hres; HRESULT hres;
while (argc) { while (argc) {
if (!strcmpiW(argv[0], f_optW)) { if (!wcsicmp(argv[0], f_optW)) {
TRACE("force opt\n"); TRACE("force opt\n");
argc--; argc--;
argv++; argv++;
}else if(!strcmpiW(argv[0], tn_optW)) { }else if(!wcsicmp(argv[0], tn_optW)) {
if (argc < 2) { if (argc < 2) {
FIXME("Missing /tn value\n"); FIXME("Missing /tn value\n");
return 1; return 1;
...@@ -358,11 +357,11 @@ int wmain(int argc, WCHAR *argv[]) ...@@ -358,11 +357,11 @@ int wmain(int argc, WCHAR *argv[])
if (argc < 2) if (argc < 2)
FIXME("Print current tasks state\n"); FIXME("Print current tasks state\n");
else if (!strcmpiW(argv[1], change_optW)) else if (!wcsicmp(argv[1], change_optW))
ret = change_command(argc - 2, argv + 2); ret = change_command(argc - 2, argv + 2);
else if (!strcmpiW(argv[1], create_optW)) else if (!wcsicmp(argv[1], create_optW))
ret = create_command(argc - 2, argv + 2); ret = create_command(argc - 2, argv + 2);
else if (!strcmpiW(argv[1], delete_optW)) else if (!wcsicmp(argv[1], delete_optW))
ret = delete_command(argc - 2, argv + 2); ret = delete_command(argc - 2, argv + 2);
else else
FIXME("Unsupported command %s\n", debugstr_w(argv[1])); FIXME("Unsupported command %s\n", debugstr_w(argv[1]));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment