Jacek Caban : mshtml: Move AddRequest call to the separated function.

Alexandre Julliard julliard at wine.codeweavers.com
Fri May 11 07:28:03 CDT 2007


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

Author: Jacek Caban <jacek at codeweavers.com>
Date:   Fri May 11 13:15:18 2007 +0200

mshtml: Move AddRequest call to the separated function.

---

 dlls/mshtml/navigate.c |   19 ++++++++++++-------
 1 files changed, 12 insertions(+), 7 deletions(-)

diff --git a/dlls/mshtml/navigate.c b/dlls/mshtml/navigate.c
index 4ee33aa..69e7b8d 100644
--- a/dlls/mshtml/navigate.c
+++ b/dlls/mshtml/navigate.c
@@ -237,6 +237,17 @@ static HRESULT read_stream_data(BSCallback *This, IStream *stream)
     return S_OK;
 }
 
+static void add_nsrequest(BSCallback *This)
+{
+    if(This->nschannel && This->nschannel->load_group) {
+        nsresult nsres = nsILoadGroup_AddRequest(This->nschannel->load_group,
+                (nsIRequest*)NSCHANNEL(This->nschannel), This->nscontext);
+
+        if(NS_FAILED(nsres))
+            ERR("AddRequest failed:%08x\n", nsres);
+    }
+}
+
 #define STATUSCLB_THIS(iface) DEFINE_THIS(BSCallback, BindStatusCallback, iface)
 
 static HRESULT WINAPI BindStatusCallback_QueryInterface(IBindStatusCallback *iface,
@@ -323,13 +334,7 @@ static HRESULT WINAPI BindStatusCallback_OnStartBinding(IBindStatusCallback *ifa
     IBinding_AddRef(pbind);
     This->binding = pbind;
 
-    if(This->nschannel && This->nschannel->load_group) {
-        nsresult nsres = nsILoadGroup_AddRequest(This->nschannel->load_group,
-                (nsIRequest*)NSCHANNEL(This->nschannel), This->nscontext);
-
-        if(NS_FAILED(nsres))
-            ERR("AddRequest failed:%08x\n", nsres);
-    }
+    add_nsrequest(This);
 
     return S_OK;
 }




More information about the wine-cvs mailing list