Hi,
I'd like to have some feedback, before I send this to wine-patches.
This patch removes a regression in the mshtml test, where the wrong
variable is called by SysFreeString, which leads sometimes to a crash (
http://test.winehq.org/data/0d7bec3578e02e1f551813e86100b59e36aec542/#group_Wine:mshtml:dom
).
Is this fix correct?
A second problem is there a need to call SysFreeString() after each
IHTMLStyle_get* when a variable isn't used any more because it does a
Sys*AllocString* call (in get_nsstyle_attr)? Or is this call useless and
automatically done when the app is terminated?
Cheers
Rico
---
dlls/mshtml/tests/dom.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/dlls/mshtml/tests/dom.c b/dlls/mshtml/tests/dom.c
index c39f79f..1e7acae 100644
--- a/dlls/mshtml/tests/dom.c
+++ b/dlls/mshtml/tests/dom.c
@@ -3225,7 +3225,7 @@ static void test_default_style(IHTMLStyle *style)
hres = IHTMLStyle_put_backgroundRepeat(style, sDefault);
ok(hres == S_OK, "put_backgroundRepeat failed: %08x\n", hres);
- SysFreeString(str);
+ SysFreeString(sDefault);
hres = IHTMLStyle_QueryInterface(style, &IID_IHTMLStyle2, (void**)&style2);
ok(hres == S_OK, "Could not get IHTMLStyle2 iface: %08x\n", hres);