From a46161bd35187d8a6b310e14f4229f2c7c107b00 Mon Sep 17 00:00:00 2001 From: sun_fan Date: Wed, 29 Sep 2021 16:21:20 +0800 Subject: [PATCH] init: fix bugs .. Signed-off-by: sun_fan --- services/param/client/param_request.c | 2 +- services/param/manager/param_utils.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/services/param/client/param_request.c b/services/param/client/param_request.c index 557a690f..fba5486d 100644 --- a/services/param/client/param_request.c +++ b/services/param/client/param_request.c @@ -275,7 +275,7 @@ int SystemGetParameterValue(ParamHandle handle, char *value, unsigned int *len) } int SystemTraversalParameter( - void (*traversalParameter)(ParamHandle handle, ParamContextPtr cookie), ParamContextPtr cookie) + void (*traversalParameter)(ParamHandle handle, void *cookie), void *cookie) { InitParamClient(); PARAM_CHECK(traversalParameter != NULL, return -1, "The param is null"); diff --git a/services/param/manager/param_utils.c b/services/param/manager/param_utils.c index 77b34a0c..4b41c4e2 100755 --- a/services/param/manager/param_utils.c +++ b/services/param/manager/param_utils.c @@ -43,7 +43,7 @@ int ReadFileInDir(const char *dirPath, const char *includeExt, int (*processFile)(const char *fileName, void *context), void *context) { if (dirPath == NULL || processFile == NULL) { - return NULL; + return -1; } DIR *pDir = opendir(dirPath); PARAM_CHECK(pDir != NULL, return -1, "Read dir :%s failed.%d", dirPath, errno); -- GitLab