2009/2/25 Paul Vriens <[email protected]>: > Nicolas Le Cam wrote: >>>>> >>>>> + >>>>> + /* We have a dll that cannot be found through >>>>> LoadLibraryExA. >>>>> This >>>>> + * is the case for .NET provided dll's. We will add the >>>>> directory >>>>> + * where the dll resides to the PATH variable when dealing >>>>> with >>>>> + * the tests for this dll. >>>>> + */ >>>>> + GetModuleFileNameA(dll, dllpath, MAX_PATH); >>>>> + *strrchr(dllpath, '\\') = '\0'; >>>>> + wine_tests[nr_of_files].maindllpath = >>>>> xmalloc(strlen(dllpath) + >>>>> 1); >>>>> + strcpy(wine_tests[nr_of_files].maindllpath, dllpath); >>>>> + } >>>> >>>> This won't work if test needs more than one dll found through >>>> LoadLibraryShim >>>> >>> Not sure what you mean as LoadLibraryShim will only return 1 dll. >> >> I mean if the test imports more than one dll that can only be found by >> LoadLibraryShim it will replace the first PATH you retrieved by the >> second one, and a message will be displayed for the first d. In my >> test I did something like that : >> >> else >> { >> char dllpath[MAX_PATH]; >> >> /* We have a dll that cannot be found through LoadLibraryExA. >> This >> * is the case for .NET provided dll's. We will add the >> directory >> * where the dll resides to the PATH variable when dealing with >> * the tests for this dll. >> */ >> GetModuleFileNameA(dll, dllpath, MAX_PATH); >> *strrchr(dllpath, '\\') = '\0'; >> if (!wine_tests[nr_of_files].maindllpath) >> wine_tests[nr_of_files].maindllpath = strmake ( NULL, >> ";%s", dllpath); >> else >> { >> char *newpath = wine_tests[nr_of_files].maindllpath; >> >> wine_tests[nr_of_files].maindllpath = strmake ( NULL, >> "%s;%s", newpath, dllpath); >> free(newpath); >> } >> } >> >> and wine_tests[nr_of_files].maindllpath = NULL; wasn't set in >> extract_test_proc >> > I still don't get it. > > The only dll that we try to load is the main dll. We don't care about all > the other imports. > > -- > Cheers, > > Paul. >
Now I get it. I thought we were trying to resolve every imports. Seems that I didn't understand the first part of extract_test_proc as I should. Sorry, I was mistaken. -- Nicolas Le Cam
