Lines Matching refs:fileName
210 static int LoadSecurityLabel(const char *fileName) in LoadSecurityLabel() argument
215 PARAM_CHECK(fileName != NULL, return -1, "Invalid filename for load"); in LoadSecurityLabel()
220 ops->securityGetLabel(fileName); in LoadSecurityLabel()
253 static int LoadDefaultParam_(const char *fileName, uint32_t mode, in LoadDefaultParam_() argument
258 realpath(fileName, realPath); in LoadDefaultParam_()
261 PARAM_LOGE("Failed to open file '%s' error:%d ", fileName, errno); in LoadDefaultParam_()
278 PARAM_LOGV("Load %u default parameters success from %s.", paramNum, fileName); in LoadDefaultParam_()
282 static int ProcessParamFile(const char *fileName, void *context) in ProcessParamFile() argument
286 return LoadDefaultParam_(fileName, mode, exclude, ARRAY_LENGTH(exclude), LoadOneParam_); in ProcessParamFile()
289 int LoadParamsFile(const char *fileName, bool onlyAdd) in LoadParamsFile() argument
291 return LoadDefaultParams(fileName, onlyAdd ? LOAD_PARAM_ONLY_ADD : LOAD_PARAM_NORMAL); in LoadParamsFile()
294 int LoadDefaultParams(const char *fileName, uint32_t mode) in LoadDefaultParams() argument
296 PARAM_CHECK(fileName != NULL, return -1, "Invalid filename for load"); in LoadDefaultParams()
297 PARAM_LOGI("Load default parameters from %s.", fileName); in LoadDefaultParams()
299 if ((stat(fileName, &st) == 0) && !S_ISDIR(st.st_mode)) { in LoadDefaultParams()
300 (void)ProcessParamFile(fileName, &mode); in LoadDefaultParams()
302 (void)ReadFileInDir(fileName, ".para", ProcessParamFile, &mode); in LoadDefaultParams()
306 return LoadSecurityLabel(fileName); in LoadDefaultParams()