Deprecate BuildConnVal() methods and update usages to ConnVal()

The later being a new method that returns IntrusivePtr
This commit is contained in:
Jon Siwek 2020-04-08 21:47:49 -07:00
parent 094d6de979
commit 2a63e4a4a2
41 changed files with 208 additions and 189 deletions

View file

@ -163,7 +163,14 @@ public:
// Activate connection_status_update timer.
void EnableStatusUpdateTimer();
[[deprecated("Remove in v4.1. Use ConnVal() instead.")]]
RecordVal* BuildConnVal();
/**
* Returns the associated "connection" record.
*/
const IntrusivePtr<RecordVal>& ConnVal();
void AppendAddl(const char* str);
LoginConn* AsLoginConn() { return login_conn; }
@ -316,8 +323,6 @@ public:
protected:
Connection() { }
// Add the given timer to expire at time t. If do_expire
// is true, then the timer is also evaluated when Bro terminates,
// otherwise not.
@ -349,7 +354,7 @@ protected:
u_char resp_l2_addr[Packet::l2_addr_len]; // Link-layer responder address, if available
double start_time, last_time;
double inactivity_timeout;
RecordVal* conn_val;
IntrusivePtr<RecordVal> conn_val;
LoginConn* login_conn; // either nil, or this
const EncapsulationStack* encapsulation; // tunnels
int suppress_event; // suppress certain events to once per conn.