aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorDeterminant <[email protected]>2018-11-19 00:54:56 -0500
committerDeterminant <[email protected]>2018-11-19 00:54:56 -0500
commit4fdac38ad5796cae03f827670655efd79d953699 (patch)
treeb20baed058ce71b7498b7b2a21575b18b0b84efb /include
parent35ffa2c1e5c7fba06c52e2c20aff2aac910921d5 (diff)
fix bug in remove_conn
Diffstat (limited to 'include')
-rw-r--r--include/salticidae/conn.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/include/salticidae/conn.h b/include/salticidae/conn.h
index 777c480..ea5ccf2 100644
--- a/include/salticidae/conn.h
+++ b/include/salticidae/conn.h
@@ -196,6 +196,7 @@ class ConnPool {
std::this_thread::get_id());
return;
}
+ assert(conn->fd != -1);
SALTICIDAE_LOG_INFO("worker %x got %s",
std::this_thread::get_id(),
std::string(*conn).c_str());
@@ -243,7 +244,7 @@ class ConnPool {
void accept_client(int, int);
conn_t add_conn(const conn_t &conn);
- void remove_conn(int fd);
+ void del_conn(const conn_t &conn);
protected:
conn_t _connect(const NetAddr &addr);