Stefan Leichter Stefan.Leichter@camline.com writes:
@@ -1711,32 +1713,35 @@ } else {
/* If the executable name is not quoted, we have to use this search loop here,
/* FIXME: what versions support this? Fails on 2000/XP
If the executable name is not quoted, we have to use this search loop here, that in CreateProcess() is not sufficient because it does not handle shell links. */ WCHAR buffer[MAX_PATH], xlpFile[MAX_PATH];
LPWSTR space, s;
LPWSTR space;
LPWSTR beg = wszApplicationName/*sei_tmp.lpFile*/;
for(s=beg; (space=strchrW(s, ' ')); s=space+1) {
int idx = space-sei_tmp.lpFile;
memcpy(buffer, sei_tmp.lpFile, idx * sizeof(WCHAR));
lstrcpynW(buffer, wszApplicationName, sizeof(buffer)/sizeof(WCHAR));
space = buffer + strlenW(buffer);
do
Searching from the end doesn't look right. This would need a test case.
Am Friday 21 August 2009 11:37:56 schrieb Alexandre Julliard:
Stefan Leichter Stefan.Leichter@camline.com writes:
@@ -1711,32 +1713,35 @@ } else {
/* If the executable name is not quoted, we have to use this search
loop here, + /* FIXME: what versions support this? Fails on 2000/XP + If the executable name is not quoted, we have to use this search loop here, that in CreateProcess() is not sufficient because it does not handle shell links. */ WCHAR buffer[MAX_PATH], xlpFile[MAX_PATH];
LPWSTR space, s;
LPWSTR space;
LPWSTR beg = wszApplicationName/*sei_tmp.lpFile*/;
for(s=beg; (space=strchrW(s, ' ')); s=space+1) {
int idx = space-sei_tmp.lpFile;
memcpy(buffer, sei_tmp.lpFile, idx * sizeof(WCHAR));
lstrcpynW(buffer, wszApplicationName,
sizeof(buffer)/sizeof(WCHAR)); + space = buffer + strlenW(buffer);
do
Searching from the end doesn't look right. This would need a test case.
This tests needs an additional program/binary, that does not need command line parameters (therefore shell32_test.exe can not be used), to be build in the test directory.
A possible way might be to create a recource from the second program, and extract this during runtime, for winetest.
The source for this is attached. It misses the modifications to Makefile.in and to fix the build dependencies, what i did not manage.
i give up here.
Stefan
Stefan Leichter Stefan.Leichter@camline.com writes:
Am Friday 21 August 2009 11:37:56 schrieb Alexandre Julliard:
Stefan Leichter Stefan.Leichter@camline.com writes:
@@ -1711,32 +1713,35 @@ } else {
/* If the executable name is not quoted, we have to use this search
loop here, + /* FIXME: what versions support this? Fails on 2000/XP + If the executable name is not quoted, we have to use this search loop here, that in CreateProcess() is not sufficient because it does not handle shell links. */ WCHAR buffer[MAX_PATH], xlpFile[MAX_PATH];
LPWSTR space, s;
LPWSTR space;
LPWSTR beg = wszApplicationName/*sei_tmp.lpFile*/;
for(s=beg; (space=strchrW(s, ' ')); s=space+1) {
int idx = space-sei_tmp.lpFile;
memcpy(buffer, sei_tmp.lpFile, idx * sizeof(WCHAR));
lstrcpynW(buffer, wszApplicationName,
sizeof(buffer)/sizeof(WCHAR)); + space = buffer + strlenW(buffer);
do
Searching from the end doesn't look right. This would need a test case.
This tests needs an additional program/binary, that does not need command line parameters (therefore shell32_test.exe can not be used), to be build in the test directory.
What you need to test is things like "test file.exe two.exe" where both exe files exist. I don't see why you can't pass arguments too, you just have to make the child a bit smarter to ignore args like "two.exe".
Am Friday 21 August 2009 14:22:14 schrieb Alexandre Julliard:
Stefan Leichter Stefan.Leichter@camline.com writes:
Am Friday 21 August 2009 11:37:56 schrieb Alexandre Julliard:
Stefan Leichter Stefan.Leichter@camline.com writes:
@@ -1711,32 +1713,35 @@ } else {
/* If the executable name is not quoted, we have to use this
search loop here, + /* FIXME: what versions support this? Fails on 2000/XP + If the executable name is not quoted, we have to use this search loop here, that in CreateProcess() is not sufficient because it does not handle shell links. */ WCHAR buffer[MAX_PATH], xlpFile[MAX_PATH];
LPWSTR space, s;
LPWSTR space;
LPWSTR beg = wszApplicationName/*sei_tmp.lpFile*/;
for(s=beg; (space=strchrW(s, ' ')); s=space+1) {
int idx = space-sei_tmp.lpFile;
memcpy(buffer, sei_tmp.lpFile, idx * sizeof(WCHAR));
lstrcpynW(buffer, wszApplicationName,
sizeof(buffer)/sizeof(WCHAR)); + space = buffer + strlenW(buffer);
do
Searching from the end doesn't look right. This would need a test case.
This tests needs an additional program/binary, that does not need command line parameters (therefore shell32_test.exe can not be used), to be build in the test directory.
What you need to test is things like "test file.exe two.exe" where both exe files exist. I don't see why you can't pass arguments too, you just have to make the child a bit smarter to ignore args like "two.exe".
When i pass arguments the code path you objects all the time is not executed. Ignoring unknow args is not possible in the shell32 tests. This must be done in include/wine/test.h. I don't like to test what breaks, when i do modifications there. -- Stefan