From 10966d9971367729c8da51e4c6b50ddd7b499f3d Mon Sep 17 00:00:00 2001 From: "wangkai399@huawei.com" Date: Fri, 6 May 2022 10:53:02 +0800 Subject: [PATCH] bug fix Signed-off-by: wangkai399@huawei.com --- samgr_client/source/remote_register_rpc.c | 6 ++++++ samgr_endpoint/source/default_client_rpc.c | 2 -- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/samgr_client/source/remote_register_rpc.c b/samgr_client/source/remote_register_rpc.c index 4678577..e839174 100755 --- a/samgr_client/source/remote_register_rpc.c +++ b/samgr_client/source/remote_register_rpc.c @@ -135,6 +135,12 @@ static void ClearRegistry(void) static void ClientInitializeRegistry(void) { +#ifndef MINI_SAMGR_LITE_RPC + if (getuid() >= ABILITY_UID_START && !g_isAbilityInited) { + ClearRegistry(); + g_isAbilityInited = TRUE; + } +#endif if (g_remoteRegister.endpoint != NULL) { return; } diff --git a/samgr_endpoint/source/default_client_rpc.c b/samgr_endpoint/source/default_client_rpc.c index 30281f8..c6b876a 100755 --- a/samgr_endpoint/source/default_client_rpc.c +++ b/samgr_endpoint/source/default_client_rpc.c @@ -169,8 +169,6 @@ static int ProxyInvoke(IClientProxy *proxy, int funcId, IpcIo *request, IOwner o MessageOption flag; MessageOptionInit(&flag); flag.flags = (notify == NULL) ? TF_OP_ASYNC : TF_OP_SYNC; - HILOG_DEBUG(HILOG_MODULE_SAMGR, "ProxyInvoke %d %lu, %lu, saId: %d\n", header->target.handle, header->target.token, - header->target.cookie, header->saId); IpcIo requestWrapper; uint8_t *data = (uint8_t *) malloc(MAX_IO_SIZE); if (data == NULL) { -- Gitee