diff --git a/frameworks/src/ipc_sdk.c b/frameworks/src/ipc_sdk.c index 8ab7647..185c320 100644 --- a/frameworks/src/ipc_sdk.c +++ b/frameworks/src/ipc_sdk.c @@ -1040,7 +1040,8 @@ static int32_t IpcGmAddGroupFriend(int32_t osAccountId, const char *appId, const return ret; } -static int32_t IpcGmDelGroupManager(int32_t osAccountId, const char *appId, const char *groupId, const char *managerAppId) +static int32_t IpcGmDelGroupManager(int32_t osAccountId, const char *appId, const char *groupId, + const char *managerAppId) { uintptr_t callCtx = 0x0; int32_t ret; diff --git a/services/device_auth.c b/services/device_auth.c index 3cf50c0..f54ab30 100644 --- a/services/device_auth.c +++ b/services/device_auth.c @@ -90,8 +90,8 @@ static int32_t AuthDevice(int32_t osAccountId, int64_t authReqId, const char *au { LOGI("Begin AuthDevice."); osAccountId = DevAuthGetRealOsAccountLocalId(osAccountId); - if (authParams == NULL) { - LOGE("The input auth params is null!"); + if ((authParams == NULL) || (osAccountId == INVALID_OS_ACCOUNT)) { + LOGE("The input auth params is invalid!"); return HC_ERR_INVALID_PARAMS; } CJson *jsonParams = CreateJsonFromString(authParams); diff --git a/services/deviceauth.gni b/services/deviceauth.gni index 243f201..4c83ae0 100644 --- a/services/deviceauth.gni +++ b/services/deviceauth.gni @@ -119,11 +119,7 @@ group_auth_account_unrelated_files = [ "${group_auth_path}/src/group_auth_manage group_auth_account_unrelated_mock_files = [ "${group_auth_path}/src/group_auth_manager/account_unrelated_group_auth_mock/account_unrelated_group_auth_mock.c" ] group_auth_account_related_mock_files = [ "${group_auth_path}/src/group_auth_manager/account_related_group_auth_mock/account_related_group_auth_mock.c" ] -database_manager_files = [ - # "${data_manager_path}/src/database_manager.c", - # "${data_manager_path}/src/database_util.c", - "${data_manager_path}/src/data_manager.c", -] +database_manager_files = [ "${data_manager_path}/src/data_manager.c" ] database_manager_lite_files = [] group_manager_files = [ diff --git a/services/group_manager/src/group_operation/peer_to_peer_group/peer_to_peer_group.c b/services/group_manager/src/group_operation/peer_to_peer_group/peer_to_peer_group.c index 2c91e66..faf5686 100644 --- a/services/group_manager/src/group_operation/peer_to_peer_group/peer_to_peer_group.c +++ b/services/group_manager/src/group_operation/peer_to_peer_group/peer_to_peer_group.c @@ -703,7 +703,8 @@ static int32_t ProcessData(int64_t requestId, CJson *jsonParams, const DeviceAut return CreateServerSession(requestId, operationCode, jsonParams, callback); } -static int32_t AddManagerWithCheck(int32_t osAccountId, const char *appId, const char *groupId, const char *managerAppId) +static int32_t AddManagerWithCheck(int32_t osAccountId, const char *appId, const char *groupId, + const char *managerAppId) { int32_t groupType = PEER_TO_PEER_GROUP; if (GetGroupTypeFromDb(osAccountId, groupId, &groupType) != HC_SUCCESS) {