new Bug in OLE

mehmet yasar myasar at free.fr
Wed Feb 27 06:04:25 CST 2002


Microsoft Visual Studio 6 is crashing when opening an existing projet,
with current CVS version of Wine (Wine20020122 was OK).

Comparing both, I have found the change that triggers the crash.
It is function StgOpenStorage in OLE32/storage32.c, line 5595 :

   hr = StorageImpl_Construct(
        newStorage,
        hFile,
        pwcsName,
        NULL,
        grfMode,
        TRUE,
-      FALSE);
+      !(Fad.nFileSizeHigh || Fad.nFileSizeLow) /* FALSE */ );
TRACE shows that Fad.nFileSizeHigh = Fad.nFileSizeLow = 0;

As you can see in TRACE the crash occurs in StorageImpl_WriteBigBloc.
I suppose Wine is trying to write to a readonly opened file ?
(because file is opened with GENERIC_READ)

I hope this will help finding a fix.

Mehmet YASAR
-------------------- BackTRACE

Unhandled exception: page fault on write access to 0x419d0000 in 32-bit 
code (0x402a6db4).
In 32-bit mode.
0x402a6db4 (NTDLL.DLL.memcpy+0x34 in libc.so.6): movl   %eax,0x0(%edi)
Backtrace:
=>0 0x402a6db4 (NTDLL.DLL.memcpy+0x34 in libc.so.6) (ebp=405d5e34)
   1 0x40899438 (StorageImpl_SaveFileHeader+0x188(This=0x403f3440) 
[storage32.c:3084] in libole32.so) (ebp=405d6058)
   2 0x408986d0 (StorageImpl_Construct+0x170(This=0x403f3440, 
hFile=0xd4, pwcsName=0x405d6414, pLkbyt=0x0, openFlags=0x10, 
fileBased=0x1, fileCreate=0x1) [storage32.c:2265] in libole32.so) 
(ebp=405d6180)
   3 0x4089bc7e (StgOpenStorage+0x21e(pwcsName=0x405d6414, 
pstgPriority=0x0, grfMode=0x10, snbExclude=0x0, reserved=0x0, 
ppstgOpen=0x405d6488) [storage32.c:5595] in libole32.so) (ebp=405d63f4)
   4 0x5009c4b2 (DEVSHL.DLL.4593+0x111 in D:\PROGRAM FILES\MICROSOFT 
VISUAL STUDIO\COMMON\MSDEV98\BIN\DEVSHL.DLL) (ebp=405d6464)

-------------------- debugmsg +ole,+storage,+file

trace:file:CreateFileA D:\Program Files\Microsoft Visual 
Studio\Common\MSDev98\Bin\mfcclwz.dll GENERIC_READ F
ILE_SHARE_READ OPEN_EXISTING
trace:file:ReadFile 212 0x405d61ec 511 0x405d5ed4 (nil)
trace:file:ReadFile 212 0x405d61ec 511 0x405d5ed4 (nil)
trace:storage:StgOpenStorage (L"Y:\\wine\\testDC\\testdc.opt", (nil), 
10, (nil), 0, 0x405d6488)
trace:file:CreateFileA Y:\wine\testDC\testdc.opt GENERIC_READ OPEN_EXISTING
trace:storage:BIGBLOCKFILE_FileInit file len 49664
trace:storage:BIGBLOCKFILE_MapPage mapped page 0 to 0x419d0000
trace:storage:StorageImpl_WriteBigBlock memcpy (0x419d0000 0x405d5e4c 512 )
wine: Unhandled exception, starting debugger...

--------------------





More information about the wine-devel mailing list