msvcrt: Fixed (_w)fopen_s with test. (try 3)
austinenglish at gmail.com
Wed Nov 10 15:15:45 CST 2010
On Wed, Nov 10, 2010 at 11:49 AM, Marvin <testbot at testbot.winehq.org> wrote:
> While running your changed tests on Windows, I think I found new failures.
> Being a bot and all I'm not very good at pattern recognition, so I might be
> wrong, but could you please double-check?
> Full results can be found at
> Your paranoid android.
> === W98SE (32 bit file) ===
> file.c:999: Test failed: smaller size block: Wrong error data ()
> file.c:1007: Test failed: smaller size block: Stdout file shouldn't contain data
It's a difference in compiler version (the failed lines aren't
affected by this change). I can trigger the same failure with just:
diff --git a/dlls/msvcrt/tests/file.c b/dlls/msvcrt/tests/file.c
index ef7b28d..73c3484 100644
@@ -36,6 +36,15 @@
static HANDLE proc_handles;
+static int (__cdecl *p_fopen_s)(FILE**, const char*, const char*);
+static void init(void)
+ HMODULE hmod = GetModuleHandleA("msvcrt.dll");
+ p_fopen_s = (void*)GetProcAddress(hmod, "fopen_s");
static void test_filbuf( void )
I also tried with Eryk's test changes, cross compiled with
austin at aw21 ~/wine-git/dlls/msvcrt/tests $ i686-pc-mingw32-gcc --version
i686-pc-mingw32-gcc (Gentoo 4.5.1 p1.2, pie-0.4.5) 4.5.1
Copyright (C) 2010 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
and that worked fine:
So if the only reason for rejecting was the test failures, please
apply the patch :-).
More information about the wine-devel