urlmon: Don't forward Start call to protocol handler in BindProtocol.

This commit is contained in:
Jacek Caban 2010-11-15 12:36:01 +01:00 committed by Alexandre Julliard
parent 97d11dbf59
commit 8c634443d0
1 changed files with 12 additions and 21 deletions

View File

@ -408,16 +408,21 @@ static HRESULT WINAPI BindProtocol_Start(IInternetProtocolEx *iface, LPCWSTR szU
DWORD grfPI, HANDLE_PTR dwReserved) DWORD grfPI, HANDLE_PTR dwReserved)
{ {
BindProtocol *This = PROTOCOL_THIS(iface); BindProtocol *This = PROTOCOL_THIS(iface);
IUri *uri;
HRESULT hres;
TRACE("(%p)->(%s %p %p %08x %lx)\n", This, debugstr_w(szUrl), pOIProtSink, TRACE("(%p)->(%s %p %p %08x %lx)\n", This, debugstr_w(szUrl), pOIProtSink,
pOIBindInfo, grfPI, dwReserved); pOIBindInfo, grfPI, dwReserved);
if(This->protocol_handler != (IInternetProtocol*)PROTOCOLHANDLER(This)) { hres = CreateUri(szUrl, Uri_CREATE_FILE_USE_DOS_PATH, 0, &uri);
FIXME("This->protocol_handler != PROTOCOLHANDLER(This)\n"); if(FAILED(hres))
return E_FAIL; return hres;
}
return IInternetProtocolEx_Start(PROTOCOLHANDLER(This), szUrl, pOIProtSink, pOIBindInfo, grfPI, dwReserved); hres = IInternetProtocolEx_StartEx(PROTOCOLEX(This), uri, pOIProtSink, pOIBindInfo,
grfPI, (HANDLE*)dwReserved);
IUri_Release(uri);
return hres;
} }
static HRESULT WINAPI BindProtocol_Continue(IInternetProtocolEx *iface, PROTOCOLDATA *pProtocolData) static HRESULT WINAPI BindProtocol_Continue(IInternetProtocolEx *iface, PROTOCOLDATA *pProtocolData)
@ -591,22 +596,8 @@ static HRESULT WINAPI ProtocolHandler_Start(IInternetProtocolEx *iface, LPCWSTR
IInternetProtocolSink *pOIProtSink, IInternetBindInfo *pOIBindInfo, IInternetProtocolSink *pOIProtSink, IInternetBindInfo *pOIBindInfo,
DWORD grfPI, HANDLE_PTR dwReserved) DWORD grfPI, HANDLE_PTR dwReserved)
{ {
BindProtocol *This = PROTOCOLHANDLER_THIS(iface); ERR("Should not be called\n");
IUri *uri; return E_NOTIMPL;
HRESULT hres;
TRACE("(%p)->(%s %p %p %08x %lx)\n", This, debugstr_w(szUrl), pOIProtSink,
pOIBindInfo, grfPI, dwReserved);
hres = CreateUri(szUrl, Uri_CREATE_FILE_USE_DOS_PATH, 0, &uri);
if(FAILED(hres))
return hres;
hres = IInternetProtocolEx_StartEx(PROTOCOLHANDLER(This), uri, pOIProtSink, pOIBindInfo,
grfPI, (HANDLE*)dwReserved);
IUri_Release(uri);
return hres;
} }
static HRESULT WINAPI ProtocolHandler_Continue(IInternetProtocolEx *iface, PROTOCOLDATA *pProtocolData) static HRESULT WINAPI ProtocolHandler_Continue(IInternetProtocolEx *iface, PROTOCOLDATA *pProtocolData)