summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/dbus-execute.h12
-rw-r--r--src/execute.c5
-rw-r--r--src/execute.h4
-rw-r--r--src/load-fragment.c2
-rw-r--r--src/mount.c2
5 files changed, 13 insertions, 12 deletions
diff --git a/src/dbus-execute.h b/src/dbus-execute.h
index 5208159695..32d58d6468 100644
--- a/src/dbus-execute.h
+++ b/src/dbus-execute.h
@@ -69,7 +69,7 @@
" <property name=\"TTYPath\" type=\"s\" access=\"read\"/>\n" \
" <property name=\"SyslogPriority\" type=\"i\" access=\"read\"/>\n" \
" <property name=\"SyslogIdentifier\" type=\"s\" access=\"read\"/>\n" \
- " <property name=\"SyslogNoPrefix\" type=\"b\" access=\"read\"/>\n" \
+ " <property name=\"SyslogLevelPrefix\" type=\"b\" access=\"read\"/>\n" \
" <property name=\"Capabilities\" type=\"s\" access=\"read\"/>\n" \
" <property name=\"SecureBits\" type=\"i\" access=\"read\"/>\n" \
" <property name=\"CapabilityBoundingSetDrop\" type=\"t\" access=\"read\"/>\n" \
@@ -83,7 +83,7 @@
" <property name=\"InaccessibleDirectories\" type=\"as\" access=\"read\"/>\n" \
" <property name=\"MountFlags\" type=\"t\" access=\"read\"/>\n" \
" <property name=\"PrivateTmp\" type=\"b\" access=\"read\"/>\n" \
- " <property name=\"NoSetSID\" type=\"b\" access=\"read\"/>\n"
+ " <property name=\"SameProcessGroup\" type=\"b\" access=\"read\"/>\n"
#define BUS_EXEC_COMMAND_INTERFACE(name) \
" <property name=\"" name "\" type=\"a(sasttuii)\" access=\"read\"/>\n"
@@ -115,7 +115,7 @@
{ interface, "CPUSchedulingPolicy", bus_execute_append_cpu_sched_policy, "i", &(context) }, \
{ interface, "CPUSchedulingPriority", bus_execute_append_cpu_sched_priority, "i", &(context) }, \
{ interface, "CPUAffinity", bus_execute_append_affinity,"ay", &(context) }, \
- { interface, "TimerSlackNSec", bus_execute_append_timer_slack_nsec, "t", &(context) }, \
+ { interface, "TimerSlackNSec", bus_execute_append_timer_slack_nsec, "t", &(context) }, \
{ interface, "CPUSchedulingResetOnFork", bus_property_append_bool, "b", &(context).cpu_sched_reset_on_fork }, \
{ interface, "NonBlocking", bus_property_append_bool, "b", &(context).non_blocking }, \
{ interface, "StandardInput", bus_execute_append_input, "s", &(context).std_input }, \
@@ -124,7 +124,7 @@
{ interface, "TTYPath", bus_property_append_string, "s", (context).tty_path }, \
{ interface, "SyslogPriority", bus_property_append_int, "i", &(context).syslog_priority }, \
{ interface, "SyslogIdentifier", bus_property_append_string, "s", (context).syslog_identifier }, \
- { interface, "SyslogNoPrefix", bus_property_append_bool, "b", &(context).syslog_no_prefix }, \
+ { interface, "SyslogLevelPrefix", bus_property_append_bool, "b", &(context).syslog_level_prefix }, \
{ interface, "Capabilities", bus_property_append_string, "s", (context).capabilities }, \
{ interface, "SecureBits", bus_property_append_int, "i", &(context).secure_bits }, \
{ interface, "CapabilityBoundingSetDrop", bus_property_append_uint64, "t", &(context).capability_bounding_set_drop }, \
@@ -138,7 +138,7 @@
{ interface, "InaccessibleDirectories", bus_property_append_strv, "as", (context).inaccessible_dirs }, \
{ interface, "MountFlags", bus_property_append_ul, "t", &(context).mount_flags }, \
{ interface, "PrivateTmp", bus_property_append_bool, "b", &(context).private_tmp }, \
- { interface, "NoSetSID", bus_property_append_bool, "b", &(context).no_setsid }
+ { interface, "SameProcessGroup", bus_property_append_bool, "b", &(context).same_pgrp }
#define BUS_EXEC_STATUS_PROPERTIES(interface, estatus, prefix) \
{ interface, prefix "StartTimestamp", bus_property_append_usec, "t", &(estatus).start_timestamp.realtime }, \
@@ -147,7 +147,7 @@
{ interface, prefix "Code", bus_property_append_int, "i", &(estatus).code }, \
{ interface, prefix "Status", bus_property_append_int, "i", &(estatus).status }
-#define BUS_EXEC_COMMAND_PROPERTY(interface, command, name) \
+#define BUS_EXEC_COMMAND_PROPERTY(interface, command, name) \
{ interface, name, bus_execute_append_command, "a(sasttuii)", (command) }
int bus_execute_append_output(Manager *m, DBusMessageIter *i, const char *property, void *data);
diff --git a/src/execute.c b/src/execute.c
index 982b7d1bcd..2acb11192d 100644
--- a/src/execute.c
+++ b/src/execute.c
@@ -197,7 +197,7 @@ static int connect_logger_as(const ExecContext *context, ExecOutput output, cons
output == EXEC_OUTPUT_KMSG ? "kmsg" : "syslog",
context->syslog_priority,
context->syslog_identifier ? context->syslog_identifier : ident,
- !context->syslog_no_prefix);
+ context->syslog_level_prefix);
if (fd != nfd) {
r = dup2(fd, nfd) < 0 ? -errno : nfd;
@@ -964,7 +964,7 @@ int exec_spawn(ExecCommand *command,
goto fail;
}
- if (!context->no_setsid)
+ if (!context->same_pgrp)
if (setsid() < 0) {
r = EXIT_SETSID;
goto fail;
@@ -1294,6 +1294,7 @@ void exec_context_init(ExecContext *c) {
c->ioprio = IOPRIO_PRIO_VALUE(IOPRIO_CLASS_BE, 0);
c->cpu_sched_policy = SCHED_OTHER;
c->syslog_priority = LOG_DAEMON|LOG_INFO;
+ c->syslog_level_prefix = true;
c->mount_flags = MS_SHARED;
}
diff --git a/src/execute.h b/src/execute.h
index 1ab6a24d9b..2e0e6cca3c 100644
--- a/src/execute.h
+++ b/src/execute.h
@@ -103,7 +103,7 @@ struct ExecContext {
int syslog_priority;
char *syslog_identifier;
- bool syslog_no_prefix;
+ bool syslog_level_prefix;
char *tcpwrap_name;
@@ -142,7 +142,7 @@ struct ExecContext {
* /bin/mount it is run in the same process group as us so
* that the autofs logic detects that it belongs to us and we
* don't enter a trigger loop. */
- bool no_setsid;
+ bool same_pgrp;
};
typedef enum ExitStatus {
diff --git a/src/load-fragment.c b/src/load-fragment.c
index 8e777fdbcf..3c0cccff49 100644
--- a/src/load-fragment.c
+++ b/src/load-fragment.c
@@ -1464,7 +1464,7 @@ static int load_from_path(Unit *u, const char *path) {
{ "SyslogIdentifier", config_parse_string_printf, &(context).syslog_identifier, section }, \
{ "SyslogFacility", config_parse_facility, &(context).syslog_priority, section }, \
{ "SyslogLevel", config_parse_level, &(context).syslog_priority, section }, \
- { "SyslogNoPrefix", config_parse_bool, &(context).syslog_no_prefix, section }, \
+ { "SyslogLevelPrefix", config_parse_bool, &(context).syslog_level_prefix, section }, \
{ "Capabilities", config_parse_capabilities, &(context), section }, \
{ "SecureBits", config_parse_secure_bits, &(context), section }, \
{ "CapabilityBoundingSetDrop", config_parse_bounding_set, &(context), section }, \
diff --git a/src/mount.c b/src/mount.c
index b99e5ffe8b..6da880eb8f 100644
--- a/src/mount.c
+++ b/src/mount.c
@@ -68,7 +68,7 @@ static void mount_init(Unit *u) {
* the same process group as us, so that the autofs kernel
* side doesn't send us another mount request while we are
* already trying to comply its last one. */
- m->exec_context.no_setsid = true;
+ m->exec_context.same_pgrp = true;
m->timer_watch.type = WATCH_INVALID;