mirror of
https://github.com/openharmony/distributedschedule_samgr_lite.git
synced 2026-07-19 17:13:31 -04:00
modify code review
Signed-off-by: chen <chenkang40@huawei.com> Change-Id: Iba4cd26d7ee1710a31e7dc8c1f4f9d89ae4133e1
This commit is contained in:
@@ -249,7 +249,7 @@ typedef struct SamgrLite {
|
||||
IUnknown *(*GetFeatureApi)(const char *serviceName, const char *feature);
|
||||
|
||||
/**
|
||||
* @brief Adds system capablity.
|
||||
* @brief Adds system capability.
|
||||
*
|
||||
* You can call this function to add the system capability. \n
|
||||
*
|
||||
|
||||
@@ -150,7 +150,7 @@ static int32 Invoke(IServerProxy *iProxy, int funcId, void *origin, IpcIo *req,
|
||||
uint32_t resource = IpcIoPopUint32(req);
|
||||
uint32_t option = IpcIoPopUint32(req);
|
||||
if (server == NULL || resource >= RES_BUTT || g_functions[resource] == NULL) {
|
||||
HILOG_ERROR(HILOG_MODULE_SAMGR, "Invalid Msg<%d, %d, %d>", resource, option, funcId);
|
||||
HILOG_ERROR(HILOG_MODULE_SAMGR, "Invalid Msg<%d, %u, %d>", resource, option, funcId);
|
||||
return EC_INVALID;
|
||||
}
|
||||
return g_functions[resource](server, option, origin, req, reply);
|
||||
|
||||
@@ -36,7 +36,7 @@ typedef struct SamgrProxy SamgrProxy;
|
||||
typedef struct SysCapImpl SysCapImpl;
|
||||
typedef enum MsgId {
|
||||
MSG_CLEAN,
|
||||
}MsgId;
|
||||
} MsgId;
|
||||
struct SamgrProxy {
|
||||
INHERIT_SERVER_IPROXY;
|
||||
};
|
||||
|
||||
@@ -543,7 +543,7 @@ void ProcGetAllSysCap(SamgrServer *server, IpcIo *req, IpcIo *reply)
|
||||
}
|
||||
int32 nextRequestIdx = startIdx;
|
||||
int32 replyNum = GetReplyNumAndNextReqIdx(sysCapablitys, startIdx, &nextRequestIdx);
|
||||
HILOG_DEBUG(HILOG_MODULE_SAMGR, "ProcGetAllSysCap replyNum: %d, size: %d, startIdx: %d, nextRequestIdx: %d",
|
||||
HILOG_DEBUG(HILOG_MODULE_SAMGR, "ProcGetAllSysCap replyNum: %d, size: %d, startIdx: %u, nextRequestIdx: %d",
|
||||
replyNum, size, startIdx, nextRequestIdx);
|
||||
WriteInt32(reply, EC_SUCCESS);
|
||||
// indicate is the last reply
|
||||
|
||||
Reference in New Issue
Block a user