mirror of
https://gitee.com/openharmony/startup_init
synced 2024-11-30 22:01:06 +00:00
!887 【OpenHarmony开源贡献者计划2022】fix warning: variable 'ret' set but not used
Merge pull request !887 from rtos_ming/unused-but-set-variable
This commit is contained in:
commit
7ae4c5ae36
@ -200,12 +200,11 @@ int LoadDefaultParams(const char *fileName, uint32_t mode)
|
||||
{
|
||||
PARAM_CHECK(fileName != NULL, return -1, "Invalid filename for load");
|
||||
PARAM_LOGI("load default parameters %s.", fileName);
|
||||
int ret = 0;
|
||||
struct stat st;
|
||||
if ((stat(fileName, &st) == 0) && !S_ISDIR(st.st_mode)) {
|
||||
ret = ProcessParamFile(fileName, &mode);
|
||||
(void)ProcessParamFile(fileName, &mode);
|
||||
} else {
|
||||
ret = ReadFileInDir(fileName, ".para", ProcessParamFile, &mode);
|
||||
(void)ReadFileInDir(fileName, ".para", ProcessParamFile, &mode);
|
||||
}
|
||||
|
||||
// load security label
|
||||
|
Loading…
Reference in New Issue
Block a user