I've a windows application that calls the win32 API function FindFirstFileA on a non-existent file. As stated in microsoft windows SDK documentation at http://msdn.microsoft.com/en-us/library/aa364418(VS.85).aspx, the function should return INVALID_HANDLE_VALUE, which is equivalent to 0xFFFFFFFF, when the file interrogated doesn't exist. Under windows, the function doesn't return INVALID_HANDLE_VALUE, even if the file doesn't exist. On the contrary, with wine under linux it successfully returns INVALID_HANDLE_VALUE. Does anyone have an interpretation for this strange difference between the behaviour of this function with windows(the one with the strange behaviour) versus wine under linux?
MSK61 wrote:> I've a windows application that calls the win32 API function FindFirstFileA on a non-existent file. As stated in microsoft windows SDK documentation at http://msdn.microsoft.com/en-us/library/aa364418(VS.85).aspx, the function should return INVALID_HANDLE_VALUE, which is equivalent to 0xFFFFFFFF, when the file interrogated doesn't exist.According to Wine tests this is correct. MSK61 wrote:> Under windows, the function doesn't return INVALID_HANDLE_VALUE, even if the file doesn't exist.Show some prove. Wine has extensive tests for this and these tests succeed on _all_ versions of windows. And Wine itself. Check your code.
Possibly Parallel Threads
- Another patch of win32-service for nice startup.
- DeviceIoControl + IOCTL_DISK_GET_DRIVE_GEOMETRY problem
- "Unable to open file..."
- warn:dosfs:DOSFS_FindUnixName - path not found
- [PATCH 5/5] win_utf8_io: Avoid forbidden functions when building for WinRT/UWP