Skip to content

Commit f7862df

Browse files
committed
Rename HttpSM::ua_session HttpSM::ua_txn
1 parent 610cd7c commit f7862df

File tree

8 files changed

+195
-185
lines changed

8 files changed

+195
-185
lines changed

proxy/InkAPI.cc

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -4676,7 +4676,7 @@ TSHttpTxnSsnGet(TSHttpTxn txnp)
46764676
sdk_assert(sdk_sanity_check_txn(txnp) == TS_SUCCESS);
46774677

46784678
HttpSM *sm = reinterpret_cast<HttpSM *>(txnp);
4679-
return reinterpret_cast<TSHttpSsn>(sm->ua_session ? (TSHttpSsn)sm->ua_session->get_parent() : nullptr);
4679+
return reinterpret_cast<TSHttpSsn>(sm->ua_txn ? (TSHttpSsn)sm->ua_txn->get_parent() : nullptr);
46804680
}
46814681

46824682
// TODO: Is this still necessary ??
@@ -5552,8 +5552,8 @@ TSHttpTxnOutgoingAddrSet(TSHttpTxn txnp, const struct sockaddr *addr)
55525552
sdk_assert(sdk_sanity_check_txn(txnp) == TS_SUCCESS);
55535553
HttpSM *sm = (HttpSM *)txnp;
55545554

5555-
sm->ua_session->set_outbound_port(ats_ip_port_host_order(addr));
5556-
sm->ua_session->set_outbound_ip(IpAddr(addr));
5555+
sm->ua_txn->set_outbound_port(ats_ip_port_host_order(addr));
5556+
sm->ua_txn->set_outbound_ip(IpAddr(addr));
55575557
return TS_ERROR;
55585558
}
55595559

@@ -5582,11 +5582,11 @@ TSHttpTxnOutgoingTransparencySet(TSHttpTxn txnp, int flag)
55825582
}
55835583

55845584
HttpSM *sm = reinterpret_cast<HttpSM *>(txnp);
5585-
if (nullptr == sm || nullptr == sm->ua_session) {
5585+
if (nullptr == sm || nullptr == sm->ua_txn) {
55865586
return TS_ERROR;
55875587
}
55885588

5589-
sm->ua_session->set_outbound_transparent(flag);
5589+
sm->ua_txn->set_outbound_transparent(flag);
55905590
return TS_SUCCESS;
55915591
}
55925592

@@ -5595,11 +5595,11 @@ TSHttpTxnClientPacketMarkSet(TSHttpTxn txnp, int mark)
55955595
{
55965596
sdk_assert(sdk_sanity_check_txn(txnp) == TS_SUCCESS);
55975597
HttpSM *sm = (HttpSM *)txnp;
5598-
if (nullptr == sm->ua_session) {
5598+
if (nullptr == sm->ua_txn) {
55995599
return TS_ERROR;
56005600
}
56015601

5602-
NetVConnection *vc = sm->ua_session->get_netvc();
5602+
NetVConnection *vc = sm->ua_txn->get_netvc();
56035603
if (nullptr == vc) {
56045604
return TS_ERROR;
56055605
}
@@ -5616,8 +5616,8 @@ TSHttpTxnServerPacketMarkSet(TSHttpTxn txnp, int mark)
56165616
HttpSM *sm = (HttpSM *)txnp;
56175617

56185618
// change the mark on an active server session
5619-
if (nullptr != sm->ua_session) {
5620-
HttpServerSession *ssn = sm->ua_session->get_server_session();
5619+
if (nullptr != sm->ua_txn) {
5620+
HttpServerSession *ssn = sm->ua_txn->get_server_session();
56215621
if (nullptr != ssn) {
56225622
NetVConnection *vc = ssn->get_netvc();
56235623
if (vc != nullptr) {
@@ -5637,11 +5637,11 @@ TSHttpTxnClientPacketTosSet(TSHttpTxn txnp, int tos)
56375637
{
56385638
sdk_assert(sdk_sanity_check_txn(txnp) == TS_SUCCESS);
56395639
HttpSM *sm = (HttpSM *)txnp;
5640-
if (nullptr == sm->ua_session) {
5640+
if (nullptr == sm->ua_txn) {
56415641
return TS_ERROR;
56425642
}
56435643

5644-
NetVConnection *vc = sm->ua_session->get_netvc();
5644+
NetVConnection *vc = sm->ua_txn->get_netvc();
56455645
if (nullptr == vc) {
56465646
return TS_ERROR;
56475647
}
@@ -5658,8 +5658,8 @@ TSHttpTxnServerPacketTosSet(TSHttpTxn txnp, int tos)
56585658
HttpSM *sm = (HttpSM *)txnp;
56595659

56605660
// change the tos on an active server session
5661-
if (nullptr != sm->ua_session) {
5662-
HttpServerSession *ssn = sm->ua_session->get_server_session();
5661+
if (nullptr != sm->ua_txn) {
5662+
HttpServerSession *ssn = sm->ua_txn->get_server_session();
56635663
if (nullptr != ssn) {
56645664
NetVConnection *vc = ssn->get_netvc();
56655665
if (vc != nullptr) {
@@ -5679,11 +5679,11 @@ TSHttpTxnClientPacketDscpSet(TSHttpTxn txnp, int dscp)
56795679
{
56805680
sdk_assert(sdk_sanity_check_txn(txnp) == TS_SUCCESS);
56815681
HttpSM *sm = (HttpSM *)txnp;
5682-
if (nullptr == sm->ua_session) {
5682+
if (nullptr == sm->ua_txn) {
56835683
return TS_ERROR;
56845684
}
56855685

5686-
NetVConnection *vc = sm->ua_session->get_netvc();
5686+
NetVConnection *vc = sm->ua_txn->get_netvc();
56875687
if (nullptr == vc) {
56885688
return TS_ERROR;
56895689
}
@@ -5700,8 +5700,8 @@ TSHttpTxnServerPacketDscpSet(TSHttpTxn txnp, int dscp)
57005700
HttpSM *sm = (HttpSM *)txnp;
57015701

57025702
// change the tos on an active server session
5703-
if (nullptr != sm->ua_session) {
5704-
HttpServerSession *ssn = sm->ua_session->get_server_session();
5703+
if (nullptr != sm->ua_txn) {
5704+
HttpServerSession *ssn = sm->ua_txn->get_server_session();
57055705
if (nullptr != ssn) {
57065706
NetVConnection *vc = ssn->get_netvc();
57075707
if (vc != nullptr) {
@@ -7683,7 +7683,7 @@ TSHttpTxnServerPush(TSHttpTxn txnp, const char *url, int url_len)
76837683
}
76847684

76857685
HttpSM *sm = reinterpret_cast<HttpSM *>(txnp);
7686-
Http2Stream *stream = dynamic_cast<Http2Stream *>(sm->ua_session);
7686+
Http2Stream *stream = dynamic_cast<Http2Stream *>(sm->ua_txn);
76877687
if (stream) {
76887688
Http2ClientSession *parent = static_cast<Http2ClientSession *>(stream->get_parent());
76897689
if (!parent->is_url_pushed(url, url_len)) {
@@ -8987,7 +8987,7 @@ TSHttpTxnCloseAfterResponse(TSHttpTxn txnp, int should_close)
89878987
HttpSM *sm = (HttpSM *)txnp;
89888988
if (should_close) {
89898989
sm->t_state.client_info.keep_alive = HTTP_NO_KEEPALIVE;
8990-
if (sm->ua_session) {
8990+
if (sm->ua_txn) {
89918991
sm->set_ua_half_close_flag();
89928992
}
89938993
}

0 commit comments

Comments
 (0)