]> Nishi Git Mirror - mandshurica.git/commitdiff
fix
authornishi <nishi@f982e544-4a7d-3444-ad1a-fde59a2a69f1>
Mon, 15 Apr 2024 02:45:48 +0000 (02:45 +0000)
committernishi <nishi@f982e544-4a7d-3444-ad1a-fde59a2a69f1>
Mon, 15 Apr 2024 02:45:48 +0000 (02:45 +0000)
git-svn-id: file:///raid/svn-main/nishi-mandshurica/trunk@29 f982e544-4a7d-3444-ad1a-fde59a2a69f1

Module/basic.c
Module/subversion.c

index c03708a39c7d150c56d7af0c13be23aa24462049..1e3497c144c518b9fc383ec9349474cadef800b7 100644 (file)
 
 #include "../Mandshurica/mandshurica.h"
 #include "../Mandshurica/ms_log.h"
+#include "../Mandshurica/ms_util.h"
 
+#include <stdlib.h>
 #include <string.h>
-#include <syslog.h>
 
 const char mod_type[] = MS_MOD_AUTH;
 
@@ -43,5 +44,17 @@ struct mandshurica_config* config;
 int mod_init(struct mandshurica_config* _config) {
        config = _config;
        config->mandshurica_log(MS_INFO, "Basic authentication Module init");
+
+       char* db = config->mandshurica_get_param("BasicDB");
+
+       if(db == NULL) {
+               config->mandshurica_log(MS_ERROR, "Basic authentication Database path is not set!");
+               return 1;
+       }
+
+       char* log = mandshurica_strcat("Basic authentication Database is ", db);
+       config->mandshurica_log(MS_INFO, log);
+       free(log);
+
        return 0;
 }
index 4141f46b2c6fbac20166fe37a3abee34644d5d95..3756e4ceeb16fa78e1e2b96f3f4a12b2f9a5fcad 100644 (file)
@@ -34,7 +34,6 @@
 
 #include <stdlib.h>
 #include <string.h>
-#include <syslog.h>
 #include <unistd.h>
 
 const char mod_type[] = MS_MOD_VCS;