Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Side by Side Diff: src/plugin/SinkPolicy.inl

Issue 4974480757620736: Issue #1356 - Improve detection of the issuer of the request (Closed)
Patch Set: Refactoring lambda and ExtractHttpHeaders functions. Coding style cleanup. Created Nov. 3, 2014, 11:36 a.m.
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View unified diff | Download patch
OLDNEW
1 #ifndef PASSTHROUGHAPP_SINKPOLICY_INL 1 #ifndef PASSTHROUGHAPP_SINKPOLICY_INL
2 #define PASSTHROUGHAPP_SINKPOLICY_INL 2 #define PASSTHROUGHAPP_SINKPOLICY_INL
3 3
4 #if _MSC_VER > 1000 4 #if _MSC_VER > 1000
5 #pragma once 5 #pragma once
6 #endif // _MSC_VER > 1000 6 #endif // _MSC_VER > 1000
7 7
8 #ifndef PASSTHROUGHAPP_SINKPOLICY_H 8 #ifndef PASSTHROUGHAPP_SINKPOLICY_H
9 #error SinkPolicy.inl requires SinkPolicy.h to be included first 9 #error SinkPolicy.inl requires SinkPolicy.h to be included first
10 #endif 10 #endif
(...skipping 364 matching lines...) Expand 10 before | Expand all | Expand 10 after
375 ATLASSERT(SUCCEEDED(hr) && spSink != 0); 375 ATLASSERT(SUCCEEDED(hr) && spSink != 0);
376 } 376 }
377 if (SUCCEEDED(hr)) 377 if (SUCCEEDED(hr))
378 { 378 {
379 hr = pSink->QueryInterface(IID_IInternetBindInfo, reinterpret_ca st<void**>(&spBindInfo)); 379 hr = pSink->QueryInterface(IID_IInternetBindInfo, reinterpret_ca st<void**>(&spBindInfo));
380 ATLASSERT(SUCCEEDED(hr) && spBindInfo != 0); 380 ATLASSERT(SUCCEEDED(hr) && spBindInfo != 0);
381 } 381 }
382 if (SUCCEEDED(hr) && !handled) 382 if (SUCCEEDED(hr) && !handled)
383 { 383 {
384 hr = pTargetProtocol->Start(szUrl, spSink, spBindInfo, grfPI, dw Reserved); 384 hr = pTargetProtocol->Start(szUrl, spSink, spBindInfo, grfPI, dw Reserved);
385 static_cast<Protocol*>(this)->m_hasOriginalStartCalled = true;
386 } 385 }
387 if (E_ABORT == hr && pSink->m_blockedInTransaction) 386 if (E_ABORT == hr && pSink->m_blockedInTransaction)
388 { 387 {
389 static_cast<Protocol*>(this)->m_shouldSupplyCustomContent = true ; 388 static_cast<Protocol*>(this)->m_shouldSupplyCustomContent = true ;
390 pSink->m_spInternetProtocolSink->ReportProgress(BINDSTATUS_MIMET YPEAVAILABLE, L"text/html"); 389 pSink->m_spInternetProtocolSink->ReportProgress(BINDSTATUS_MIMET YPEAVAILABLE, L"text/html");
391 pSink->m_spInternetProtocolSink->ReportData(BSCF_FIRSTDATANOTIFI CATION, 0, static_cast<ULONG>(g_blockedByABPPage.size())); 390 pSink->m_spInternetProtocolSink->ReportData(BSCF_FIRSTDATANOTIFI CATION, 0, static_cast<ULONG>(g_blockedByABPPage.size()));
392 return S_OK; 391 return S_OK;
393 } 392 }
394 return hr; 393 return hr;
395 } 394 }
(...skipping 15 matching lines...) Expand all
411 template <class Protocol, class Sink> 410 template <class Protocol, class Sink>
412 inline Protocol* CustomSinkStartPolicy<Protocol, Sink>::GetProtocol( 411 inline Protocol* CustomSinkStartPolicy<Protocol, Sink>::GetProtocol(
413 const Sink* pSink) 412 const Sink* pSink)
414 { 413 {
415 return Protocol::ComObjectClass::GetProtocol(pSink); 414 return Protocol::ComObjectClass::GetProtocol(pSink);
416 } 415 }
417 416
418 } // end namespace PassthroughAPP 417 } // end namespace PassthroughAPP
419 418
420 #endif // PASSTHROUGHAPP_SINKPOLICY_INL 419 #endif // PASSTHROUGHAPP_SINKPOLICY_INL
OLDNEW

Powered by Google App Engine
This is Rietveld