summaryrefslogtreecommitdiffstats
path: root/src/login
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2018-05-22 16:14:49 +0200
committerGitHub <noreply@github.com>2018-05-22 16:14:49 +0200
commit8904ab86b0397e64846e4b7418584f7120626d9f (patch)
treead6c3ef887dd1019933b618a1194a6db699245a2 /src/login
parentpid1: fix ShowStatus property (diff)
parentconf-parser: make use of free_and_replace() at one more place (diff)
downloadsystemd-8904ab86b0397e64846e4b7418584f7120626d9f.tar.xz
systemd-8904ab86b0397e64846e4b7418584f7120626d9f.zip
Merge pull request #9062 from poettering/parse-conf-macro
add new CONFIG_PARSER_PROTOTYPE() macro
Diffstat (limited to 'src/login')
-rw-r--r--src/login/logind-action.h5
-rw-r--r--src/login/logind-user.h3
-rw-r--r--src/login/logind.h5
3 files changed, 9 insertions, 4 deletions
diff --git a/src/login/logind-action.h b/src/login/logind-action.h
index 70439d767c..89c2dfddb4 100644
--- a/src/login/logind-action.h
+++ b/src/login/logind-action.h
@@ -7,6 +7,8 @@
Copyright 2012 Lennart Poettering
***/
+#include "conf-parser.h"
+
typedef enum HandleAction {
HANDLE_IGNORE,
HANDLE_POWEROFF,
@@ -36,4 +38,5 @@ const char* handle_action_to_string(HandleAction h) _const_;
HandleAction handle_action_from_string(const char *s) _pure_;
const char* manager_target_for_action(HandleAction handle);
-int config_parse_handle_action(const char *unit, const char *filename, unsigned line, const char *section, unsigned section_line, const char *lvalue, int ltype, const char *rvalue, void *data, void *userdata);
+
+CONFIG_PARSER_PROTOTYPE(config_parse_handle_action);
diff --git a/src/login/logind-user.h b/src/login/logind-user.h
index 18a80b3fdf..25b52ef792 100644
--- a/src/login/logind-user.h
+++ b/src/login/logind-user.h
@@ -9,6 +9,7 @@
typedef struct User User;
+#include "conf-parser.h"
#include "list.h"
#include "logind.h"
@@ -80,4 +81,4 @@ UserState user_state_from_string(const char *s) _pure_;
int bus_user_method_terminate(sd_bus_message *message, void *userdata, sd_bus_error *error);
int bus_user_method_kill(sd_bus_message *message, void *userdata, sd_bus_error *error);
-int config_parse_compat_user_tasks_max(const char *unit, const char *filename, unsigned line, const char *section, unsigned section_line, const char *lvalue, int ltype, const char *rvalue, void *data, void *userdata);
+CONFIG_PARSER_PROTOTYPE(config_parse_compat_user_tasks_max);
diff --git a/src/login/logind.h b/src/login/logind.h
index 498a371361..bc6e696550 100644
--- a/src/login/logind.h
+++ b/src/login/logind.h
@@ -13,6 +13,7 @@
#include "sd-bus.h"
#include "sd-event.h"
+#include "conf-parser.h"
#include "hashmap.h"
#include "list.h"
#include "set.h"
@@ -179,8 +180,8 @@ const struct ConfigPerfItem* logind_gperf_lookup(const char *key, GPERF_LEN_TYPE
int manager_set_lid_switch_ignore(Manager *m, usec_t until);
-int config_parse_n_autovts(const char *unit, const char *filename, unsigned line, const char *section, unsigned section_line, const char *lvalue, int ltype, const char *rvalue, void *data, void *userdata);
-int config_parse_tmpfs_size(const char *unit, const char *filename, unsigned line, const char *section, unsigned section_line, const char *lvalue, int ltype, const char *rvalue, void *data, void *userdata);
+CONFIG_PARSER_PROTOTYPE(config_parse_n_autovts);
+CONFIG_PARSER_PROTOTYPE(config_parse_tmpfs_size);
int manager_get_session_from_creds(Manager *m, sd_bus_message *message, const char *name, sd_bus_error *error, Session **ret);
int manager_get_user_from_creds(Manager *m, sd_bus_message *message, uid_t uid, sd_bus_error *error, User **ret);