Bug 1158543 - Remove SpdyConnectTransaction::mRequestHead and make the base class mRequestHead protected; r=mcmanus

There is no need to have two separate variables for the same thing
in the same object.
This commit is contained in:
Ehsan Akhgari 2015-04-25 09:52:51 -04:00
parent a4ca187e8c
commit 6bb653df94
4 changed files with 2 additions and 6 deletions

View File

@ -95,8 +95,8 @@ NullHttpTransaction::NullHttpTransaction(nsHttpConnectionInfo *ci,
uint32_t caps)
: mStatus(NS_OK)
, mCaps(caps | NS_HTTP_ALLOW_KEEPALIVE)
, mCapsToClear(0)
, mRequestHead(nullptr)
, mCapsToClear(0)
, mIsDone(false)
, mClaimed(false)
, mCallbacks(callbacks)

View File

@ -56,6 +56,7 @@ private:
nsresult mStatus;
protected:
uint32_t mCaps;
nsHttpRequestHead *mRequestHead;
private:
// mCapsToClear holds flags that should be cleared in mCaps, e.g. unset
// NS_HTTP_REFRESH_DNS when DNS refresh request has completed to avoid
@ -65,7 +66,6 @@ private:
// bitfields should be allowed: 'lost races' will thus err on the
// conservative side, e.g. by going ahead with a 2nd DNS refresh.
Atomic<uint32_t> mCapsToClear;
nsHttpRequestHead *mRequestHead;
bool mIsDone;
bool mClaimed;

View File

@ -1022,9 +1022,6 @@ SpdyConnectTransaction::SpdyConnectTransaction(nsHttpConnectionInfo *ci,
SpdyConnectTransaction::~SpdyConnectTransaction()
{
LOG(("SpdyConnectTransaction dtor %p\n", this));
if (mRequestHead) {
delete mRequestHead;
}
if (mDrivingTransaction) {
// requeue it I guess. This should be gone.

View File

@ -209,7 +209,6 @@ private:
nsCString mConnectString;
uint32_t mConnectStringOffset;
nsHttpRequestHead *mRequestHead;
nsAHttpConnection *mSession;
nsAHttpSegmentReader *mSegmentReader;