Indrek Altpere : mshtml: Add NULL check to avoid crashing due to Gecko bug.
Module: wine Branch: master Commit: 55c03ad4d219ae8ba78ec30e6ff1ad82070bd2ab URL: http://source.winehq.org/git/wine.git/?a=commit;h=55c03ad4d219ae8ba78ec30e6f... Author: Indrek Altpere <efbiaiinzinz(a)hotmail.com> Date: Mon Jun 1 14:11:21 2015 +0300 mshtml: Add NULL check to avoid crashing due to Gecko bug. --- dlls/mshtml/htmlcurstyle.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/dlls/mshtml/htmlcurstyle.c b/dlls/mshtml/htmlcurstyle.c index 5f6cb35..f0b0d98 100644 --- a/dlls/mshtml/htmlcurstyle.c +++ b/dlls/mshtml/htmlcurstyle.c @@ -1343,6 +1343,11 @@ HRESULT HTMLCurrentStyle_Create(HTMLElement *elem, IHTMLCurrentStyle **p) return E_FAIL; } + if(!nsstyle) { + ERR("GetComputedStyle returned NULL nsstyle\n"); + return E_FAIL; + } + ret = heap_alloc_zero(sizeof(HTMLCurrentStyle)); if(!ret) { nsIDOMCSSStyleDeclaration_Release(nsstyle);
participants (1)
-
Alexandre Julliard