static HRESULT WINAPI HttpNegotiate_OnResponse(IHttpNegotiate *iface, DWORD dwResponseCode, LPCWSTR szResponseHeaders, LPCWSTR szRequestHeaders, LPWSTR *pszAdditionalRequestHeaders) { BindStatusCallback *This = impl_from_IHttpNegotiate(iface); TRACE("(%p)->(%d %s %s %p)\n", This, dwResponseCode, debugstr_w(szResponseHeaders), debugstr_w(szRequestHeaders), pszAdditionalRequestHeaders); return S_OK; }
static HRESULT WINAPI BSCHttpNegotiate_OnResponse(IHttpNegotiate *iface, DWORD code, LPCWSTR resp_headers, LPCWSTR req_headers, LPWSTR *add_reqheaders) { BindStatusCallback *This = impl_from_IHttpNegotiate(iface); TRACE("(%p)->(%d %s %s %p)\n", This, code, debugstr_w(resp_headers), debugstr_w(req_headers), add_reqheaders); This->request->status = code; return S_OK; }
static HRESULT WINAPI HttpNegotiate_BeginningTransaction(IHttpNegotiate *iface, LPCWSTR szURL, LPCWSTR szHeaders, DWORD dwReserved, LPWSTR *pszAdditionalHeaders) { ExtensionService *This = impl_from_IHttpNegotiate(iface); TRACE("(%p)->(%s %s %x %p)\n", This, debugstr_w(szURL), debugstr_w(szHeaders), dwReserved, pszAdditionalHeaders); if(!pszAdditionalHeaders) return E_INVALIDARG; *pszAdditionalHeaders = hlink_co_strdupW(This->headers); return S_OK; }
static HRESULT WINAPI HttpNegotiate_BeginningTransaction(IHttpNegotiate *iface, LPCWSTR szURL, LPCWSTR szHeaders, DWORD dwReserved, LPWSTR *pszAdditionalHeaders) { BindStatusCallback *This = impl_from_IHttpNegotiate(iface); TRACE("(%p)->(%s %s %d %p)\n", This, debugstr_w(szURL), debugstr_w(szHeaders), dwReserved, pszAdditionalHeaders); if(This->headers) { int size = (strlenW(This->headers)+1)*sizeof(WCHAR); *pszAdditionalHeaders = CoTaskMemAlloc(size); memcpy(*pszAdditionalHeaders, This->headers, size); } return S_OK; }
static HRESULT WINAPI BSCHttpNegotiate_BeginningTransaction(IHttpNegotiate *iface, LPCWSTR url, LPCWSTR headers, DWORD reserved, LPWSTR *add_headers) { BindStatusCallback *This = impl_from_IHttpNegotiate(iface); const struct reqheader *entry; WCHAR *buff, *ptr; TRACE("(%p)->(%s %s %d %p)\n", This, debugstr_w(url), debugstr_w(headers), reserved, add_headers); *add_headers = NULL; if (list_empty(&This->request->reqheaders)) return S_OK; buff = CoTaskMemAlloc(This->request->reqheader_size*sizeof(WCHAR)); if (!buff) return E_OUTOFMEMORY; ptr = buff; LIST_FOR_EACH_ENTRY(entry, &This->request->reqheaders, struct reqheader, entry) { lstrcpyW(ptr, entry->header); ptr += SysStringLen(entry->header); lstrcpyW(ptr, colspaceW); ptr += sizeof(colspaceW)/sizeof(WCHAR)-1; lstrcpyW(ptr, entry->value); ptr += SysStringLen(entry->value); lstrcpyW(ptr, crlfW); ptr += sizeof(crlfW)/sizeof(WCHAR)-1; } *add_headers = buff; return S_OK; }
static ULONG WINAPI HttpNegotiate_Release(IHttpNegotiate *iface) { BindStatusCallback *This = impl_from_IHttpNegotiate(iface); return IBindStatusCallback_Release(&This->IBindStatusCallback_iface); }
static HRESULT WINAPI HttpNegotiate_QueryInterface(IHttpNegotiate *iface, REFIID riid, void **ppv) { BindStatusCallback *This = impl_from_IHttpNegotiate(iface); return IBindStatusCallback_QueryInterface(&This->IBindStatusCallback_iface, riid, ppv); }
static ULONG WINAPI BSCHttpNegotiate_AddRef(IHttpNegotiate *iface) { BindStatusCallback *This = impl_from_IHttpNegotiate(iface); return IBindStatusCallback_AddRef(&This->IBindStatusCallback_iface); }
static ULONG WINAPI HttpNegotiate_Release(IHttpNegotiate *iface) { ExtensionService *This = impl_from_IHttpNegotiate(iface); return IUnknown_Release(This->outer_unk); }
static HRESULT WINAPI HttpNegotiate_QueryInterface(IHttpNegotiate *iface, REFIID riid, void **ppv) { ExtensionService *This = impl_from_IHttpNegotiate(iface); return IUnknown_QueryInterface(This->outer_unk, riid, ppv); }