Jacek Caban : mshtml: Test for NULL nscontainer in set_event_handler_disp.

Alexandre Julliard julliard at winehq.org
Mon Oct 13 06:37:46 CDT 2008


Module: wine
Branch: master
Commit: e23d0e077c0c13bbd73658cf09630405e055c614
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=e23d0e077c0c13bbd73658cf09630405e055c614

Author: Jacek Caban <jacek at codeweavers.com>
Date:   Fri Oct 10 15:49:45 2008 -0500

mshtml: Test for NULL nscontainer in set_event_handler_disp.

---

 dlls/mshtml/htmlevent.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/dlls/mshtml/htmlevent.c b/dlls/mshtml/htmlevent.c
index aaf7541..e7f581a 100644
--- a/dlls/mshtml/htmlevent.c
+++ b/dlls/mshtml/htmlevent.c
@@ -531,7 +531,7 @@ static HRESULT set_event_handler_disp(event_target_t **event_target, HTMLDocumen
         return S_OK;
     IDispatch_AddRef(disp);
 
-    if(event_info[eid].flags & EVENT_DEFAULTLISTENER) {
+    if(doc->nscontainer && (event_info[eid].flags & EVENT_DEFAULTLISTENER)) {
         if(!doc->nscontainer->event_vector) {
             doc->nscontainer->event_vector = heap_alloc_zero(EVENTID_LAST*sizeof(BOOL));
             if(!doc->nscontainer->event_vector)




More information about the wine-cvs mailing list