From f3747f758ae58aee5b6c86b1827ea3994d6fb153 Mon Sep 17 00:00:00 2001 From: Hwankyu Jhun Date: Wed, 21 Sep 2022 09:00:09 +0000 Subject: [PATCH] Fix the implementation related to rpc-port - Removes unnecessary log prints - Fixes the wrong implementation about rpc_port_parcel_header_h. Change-Id: I0a9676c1823a372d61fb30edaab8935490780de4 Signed-off-by: Hwankyu Jhun --- idlc/gen/c_proxy_body_gen_cb.h | 3 --- idlc/gen/c_stub_body_gen_cb.h | 1 - idlc/gen/cpp_proxy_body_gen_cb.h | 2 -- idlc/gen/cpp_stub_body_gen.cc | 1 - idlc/gen/cpp_stub_body_gen_cb.h | 3 +-- 5 files changed, 1 insertion(+), 9 deletions(-) diff --git a/idlc/gen/c_proxy_body_gen_cb.h b/idlc/gen/c_proxy_body_gen_cb.h index 5142739..780e4b5 100644 --- a/idlc/gen/c_proxy_body_gen_cb.h +++ b/idlc/gen/c_proxy_body_gen_cb.h @@ -764,7 +764,6 @@ void __invoke_(__h h) rpc_port_parcel_get_header(parcel_, &header_); rpc_port_parcel_header_set_tag(header_, TIDL_VERSION); rpc_port_parcel_header_get_seq_num(header_, &seq_num_); - _W("[Version] \"%s\", [Sequence] %d", TIDL_VERSION, seq_num_); rpc_port_parcel_write_int32(parcel_, __METHOD_); @@ -836,7 +835,6 @@ R"__c_cb( rpc_port_parcel_get_header(parcel_, &header_); rpc_port_parcel_header_set_tag(header_, TIDL_VERSION); rpc_port_parcel_header_get_seq_num(header_, &seq_num_); - _W("[Version] \"%s\", [Sequence] %d", TIDL_VERSION, seq_num_); rpc_port_parcel_write_int32(parcel_, __METHOD_); @@ -866,7 +864,6 @@ R"__c_cb( tag_ = nullptr; rpc_port_parcel_header_get_tag(header_, &tag_); if (tag_ && tag_[0] != '\0') { - _W("[Version] %s", tag_); rpc_port_parcel_header_get_seq_num(header_, &recv_seq_num_); if (recv_seq_num_ != seq_num_) { _E("Invalid protocol. %d", recv_seq_num_); diff --git a/idlc/gen/c_stub_body_gen_cb.h b/idlc/gen/c_stub_body_gen_cb.h index 6c63fb5..aafe2f1 100644 --- a/idlc/gen/c_stub_body_gen_cb.h +++ b/idlc/gen/c_stub_body_gen_cb.h @@ -715,7 +715,6 @@ static int ____method__handler(rpc_port_h port, rpc_p rpc_port_parcel_get_header(parcel, &header_); rpc_port_parcel_header_get_seq_num(header_, &seq_num_); - _W("[Sequence] %d", seq_num_); diff --git a/idlc/gen/cpp_proxy_body_gen_cb.h b/idlc/gen/cpp_proxy_body_gen_cb.h index d81ebb1..58e870a 100644 --- a/idlc/gen/cpp_proxy_body_gen_cb.h +++ b/idlc/gen/cpp_proxy_body_gen_cb.h @@ -41,7 +41,6 @@ R"__cpp_cb( rpc_port_parcel_header_set_tag(header_, TIDL_VERSION); int seq_num_ = -1; rpc_port_parcel_header_get_seq_num(header_, &seq_num_); - _W("[Version] \"%s\", [Sequence] %d", TIDL_VERSION, seq_num_); rpc_port_parcel_write_int32(p, static_cast(MethodId::)); // Send @@ -78,7 +77,6 @@ R"__cpp_cb( rpc_port_parcel_header_get_tag(header_, &tag_); std::unique_ptr tag_auto_(tag_, std::free); if (tag_ && tag_[0] != '\0') { - _W("[Version] %s", tag_); int seq_num_received_ = -1; rpc_port_parcel_header_get_seq_num(header_, &seq_num_received_); if (seq_num_received_ != seq_num_) { diff --git a/idlc/gen/cpp_stub_body_gen.cc b/idlc/gen/cpp_stub_body_gen.cc index 455785d..2c51d1f 100644 --- a/idlc/gen/cpp_stub_body_gen.cc +++ b/idlc/gen/cpp_stub_body_gen.cc @@ -242,7 +242,6 @@ void CppStubBodyGen::GenInvocation(std::ofstream& stream, } m += "ret = rpc_port_parcel_send(result, port);\n"; - m += "_I(\"Parcel send result(%d)\", ret);\n"; stream << AddIndent(TAB_SIZE * 3, m); } diff --git a/idlc/gen/cpp_stub_body_gen_cb.h b/idlc/gen/cpp_stub_body_gen_cb.h index 3bcac51..c88e659 100644 --- a/idlc/gen/cpp_stub_body_gen_cb.h +++ b/idlc/gen/cpp_stub_body_gen_cb.h @@ -119,7 +119,7 @@ int [NAME]::OnReceivedCB(const char* sender, const char* instance, rpc_port_h po auto* cxt = static_cast<[NAME]*>(data); rpc_port_parcel_h p; rpc_port_parcel_h result; - rpc_port_parcel_h header; + rpc_port_parcel_header_h header; int seq_num = -1; int cmd; int ret; @@ -152,7 +152,6 @@ int [NAME]::OnReceivedCB(const char* sender, const char* instance, rpc_port_h po rpc_port_parcel_get_header(p, &header); rpc_port_parcel_header_get_seq_num(header, &seq_num); - _W("[Sequence] %d", seq_num); rpc_port_parcel_create(&result); rpc_port_parcel_get_header(result, &header); -- 2.7.4