From 899de79214f032e34d0ec360fdadded6d638d41e Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Thu, 28 Mar 2024 15:44:44 +0800 Subject: [PATCH] Auto PR from release/0.7 to main (#430) * fix_epoll_oneshot * add judgement for conflicted ONE_SHOT flag in add_interests() (#422) improve logic in add_interests() and rm_interests() * fix gcc13 (#429) --------- Co-authored-by: lihuiba Co-authored-by: Huiba Li --- common/iovector.h | 5 +++++ net/datagram_socket.h | 2 ++ rpc/rpc.cpp | 4 ++++ 3 files changed, 11 insertions(+) diff --git a/common/iovector.h b/common/iovector.h index 7454462e..f0423cad 100644 --- a/common/iovector.h +++ b/common/iovector.h @@ -39,6 +39,10 @@ limitations under the License. #include #include +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Wunknown-warning-option" +#pragma GCC diagnostic ignored "-Wzero-length-bounds" + inline bool operator == (const iovec& a, const iovec& b) { return a.iov_base == b.iov_base && a.iov_len == b.iov_len; @@ -1075,3 +1079,4 @@ class SmartCloneIOV #undef IF_ASSERT_RETURN +#pragma GCC diagnostic pop \ No newline at end of file diff --git a/net/datagram_socket.h b/net/datagram_socket.h index 3c763400..344b44a6 100644 --- a/net/datagram_socket.h +++ b/net/datagram_socket.h @@ -50,6 +50,8 @@ class IDatagramSocket : public IMessage, ssize_t recv(B* buf, S count, int flags = 0) { return cast()->recv(buf, count, nullptr, nullptr, flags); } + using IMessage::recv; + using IMessage::send; }; class UDPSocket : public IDatagramSocket { diff --git a/rpc/rpc.cpp b/rpc/rpc.cpp index 793a290f..7a9920a9 100644 --- a/rpc/rpc.cpp +++ b/rpc/rpc.cpp @@ -324,8 +324,12 @@ namespace rpc { if (unlikely(!m_running)) return -1; +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Wunknown-warning-option" +#pragma GCC diagnostic ignored "-Wdangling-pointer" ThreadLink node; m_list.push_back(&node); +#pragma GCC diagnostic pop DEFER(m_list.erase(&node)); // stream serve refcount int stream_serv_count = 0;