From 1fcedefadb7229f8ac06e373a58f223206fab98f Mon Sep 17 00:00:00 2001 From: SangYoun Kwak Date: Wed, 4 May 2022 14:47:18 +0900 Subject: [PATCH] Modify conf keyword, UPPER_SNAKE_CASE to PascalCase Change-Id: I8791c448ab4136be1c17c8a76d2ebfe268d6c2e3 Signed-off-by: SangYoun Kwak --- conf/storage.conf | 8 ++++---- src/storage/storage.c | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/conf/storage.conf b/conf/storage.conf index 331e786..188f5e8 100644 --- a/conf/storage.conf +++ b/conf/storage.conf @@ -1,7 +1,7 @@ -[LOWSTORAGE] +[StorageUsageLevelThreshold] #5% -WARNING_LEVEL=5 +WarningLevel=5 #0.1% -CRITICAL_LEVEL=0.1 +CriticalLevel=0.1 #0.0% -FULL_LEVEL=0 +FullLevel=0 diff --git a/src/storage/storage.c b/src/storage/storage.c index 1cbf337..7d21b7f 100644 --- a/src/storage/storage.c +++ b/src/storage/storage.c @@ -667,7 +667,7 @@ static int load_config(struct parse_result *result, void *user_data) if (!info) return -EINVAL; - if (!MATCH(result->section, "LOWSTORAGE")) + if (!MATCH(result->section, "StorageUsageLevelThreshold")) return -EINVAL; _D("%s,%s,%s", result->section, result->name, result->value); @@ -675,11 +675,11 @@ static int load_config(struct parse_result *result, void *user_data) name = result->name; value = result->value; - if (MATCH(name, "WARNING_LEVEL")) + if (MATCH(name, "WarningLevel")) info->warning_level = (double)atof(value); - else if (MATCH(name, "CRITICAL_LEVEL")) + else if (MATCH(name, "CriticalLevel")) info->critical_level = (double)atof(value); - else if (MATCH(name, "FULL_LEVEL")) + else if (MATCH(name, "FullLevel")) info->full_level = (double)atof(value); return 0; -- 2.7.4