mirror of
https://github.com/EQEmu/Server.git
synced 2025-12-13 18:51:29 +00:00
Use casts to silence ASan complaints
I don't think these are actually causing any real problems, ASan complains about them though since it's kind of a code smell I guess and a potential source of problems. But our case is fine, so cast to silence them.
This commit is contained in:
parent
66f89416d5
commit
cafae9d8c6
@ -51,7 +51,7 @@ namespace EQ {
|
|||||||
void Stop() {
|
void Stop() {
|
||||||
if (m_timer) {
|
if (m_timer) {
|
||||||
uv_close((uv_handle_t*)m_timer, [](uv_handle_t* handle) {
|
uv_close((uv_handle_t*)m_timer, [](uv_handle_t* handle) {
|
||||||
delete handle;
|
delete (uv_timer_t *)handle;
|
||||||
});
|
});
|
||||||
m_timer = nullptr;
|
m_timer = nullptr;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
#include "../event/event_loop.h"
|
#include "../event/event_loop.h"
|
||||||
|
|
||||||
void on_close_handle(uv_handle_t* handle) {
|
void on_close_handle(uv_handle_t* handle) {
|
||||||
delete handle;
|
delete (uv_tcp_t *)handle;
|
||||||
}
|
}
|
||||||
|
|
||||||
EQ::Net::TCPConnection::TCPConnection(uv_tcp_t *socket)
|
EQ::Net::TCPConnection::TCPConnection(uv_tcp_t *socket)
|
||||||
@ -115,7 +115,7 @@ void EQ::Net::TCPConnection::Disconnect()
|
|||||||
connection->m_on_disconnect_cb(connection);
|
connection->m_on_disconnect_cb(connection);
|
||||||
}
|
}
|
||||||
|
|
||||||
delete handle;
|
delete (uv_tcp_t *)handle;
|
||||||
});
|
});
|
||||||
m_socket = nullptr;
|
m_socket = nullptr;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
#include "../event/event_loop.h"
|
#include "../event/event_loop.h"
|
||||||
|
|
||||||
void on_close_tcp_server_handle(uv_handle_t* handle) {
|
void on_close_tcp_server_handle(uv_handle_t* handle) {
|
||||||
delete handle;
|
delete (uv_tcp_t *)handle;
|
||||||
}
|
}
|
||||||
|
|
||||||
EQ::Net::TCPServer::TCPServer()
|
EQ::Net::TCPServer::TCPServer()
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user