Paul Vriens : mshtml/tests: Cast-qual warning fix.

Paul Vriens paul.vriens.wine at gmail.com
Sat Jan 13 08:33:12 CST 2007


Michael Stefaniuc wrote:
> Alexandre Julliard wrote:
>> Module: wine
>> Branch: master
>> Commit: 6338caa9eda8eda98dad9a89a8e71c6ea37bd168
>> URL:    http://source.winehq.org/git/wine.git/?a=commit;h=6338caa9eda8eda98dad9a89a8e71c6ea37bd168
>>
>> Author: Paul Vriens <paul.vriens.wine at gmail.com>
>> Date:   Fri Jan 12 14:26:05 2007 +0100
>>
>> mshtml/tests: Cast-qual warning fix.
> 
> This breaks compilation with older gcc versions. At least with gcc-3.1.1
> used by Smatch.
> 
> dlls/mshtml/tests/htmldoc.c: In function `test_Load':
> dlls/mshtml/tests/htmldoc.c:1806: invalid initializer
> make[2]: *** [htmldoc.o] Error 1
> 
Hi,

does the attached patch fix this? If 
yes, I'll produce patches for mshtml, 
crypt32 and secur32 which all suffer the 
same issue.

Cheers,

Paul.
-------------- next part --------------
diff --git a/dlls/mshtml/tests/htmldoc.c b/dlls/mshtml/tests/htmldoc.c
index 0815c01..99a15cc 100644
--- a/dlls/mshtml/tests/htmldoc.c
+++ b/dlls/mshtml/tests/htmldoc.c
@@ -1803,7 +1803,9 @@ static void test_Load(IPersistMoniker *persist)
 {
     IBindCtx *bind;
     HRESULT hres;
-    static WCHAR sz_html_clientsite_objectparam[] = SZ_HTML_CLIENTSITE_OBJECTPARAM;
+    static WCHAR sz_html_clientsite_objectparam[MAX_PATH];
+
+    lstrcpyW(sz_html_clientsite_objectparam, SZ_HTML_CLIENTSITE_OBJECTPARAM);
 
     test_readyState((IUnknown*)persist);
 


More information about the wine-devel mailing list