From f95f4e39db0fe10cd7b6be9fd5f5e0e96f887dc0 Mon Sep 17 00:00:00 2001 From: molese Date: Tue, 30 Nov 2021 12:34:00 +0600 Subject: [PATCH 1/2] src/default.scm: add missing logic in system-hostname-check Signed-off-by: molese --- src/default.scm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/default.scm b/src/default.scm index 85b7449..c044063 100644 --- a/src/default.scm +++ b/src/default.scm @@ -7,10 +7,11 @@ ;; FIXME(Krey): Process DOMAIN -;; function to print error if environment variable 'HOSTNAME' is not set or if it's value is empty +;; function to throw error if environment variable 'HOSTNAME' is not set + ; or if it's value is empty ;; FIXME-QA(Molese): Needs test (define system-hostname-check (lambda () - (if (not (system-hostname-set?)) + (if (not (eq nil (getenv "HOSTNAME"))) (throw 1 "Environment variable 'HOSTNAME' is not set, unable to apply sufficient configuration")) (if (eq? (getenv "HOSTNAME") #f) (throw 1 "Environment variable 'HOSTNAME' is empty, unable to apply sufficient configuration")))) -- 2.48.1 From 83d2cba944019ca55a7cc4758452362c7a9a358f Mon Sep 17 00:00:00 2001 From: molese Date: Tue, 30 Nov 2021 12:37:36 +0600 Subject: [PATCH 2/2] src/default.scm: add unnecessary not statement in system-hostname-check Signed-off-by: molese --- src/default.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/default.scm b/src/default.scm index c044063..3a10227 100644 --- a/src/default.scm +++ b/src/default.scm @@ -11,7 +11,7 @@ ; or if it's value is empty ;; FIXME-QA(Molese): Needs test (define system-hostname-check (lambda () - (if (not (eq nil (getenv "HOSTNAME"))) + (if (eq nil (getenv "HOSTNAME")) (throw 1 "Environment variable 'HOSTNAME' is not set, unable to apply sufficient configuration")) (if (eq? (getenv "HOSTNAME") #f) (throw 1 "Environment variable 'HOSTNAME' is empty, unable to apply sufficient configuration")))) -- 2.48.1