}
static void ask_password_agent_open_if_enabled(void) {
-
/* Open the password agent as a child process if necessary */
if (arg_dry_run)
}
static bool install_client_side(void) {
-
/* Decides when to execute enable/disable/... operations
* client-side rather than server-side. */
}
static int list_dependencies_get_dependencies(sd_bus *bus, const char *name, char ***deps) {
-
struct DependencyStatusInfo {
char **dep[5];
} info = {};
}
static int unit_is_enabled(int argc, char *argv[], void *userdata) {
-
_cleanup_strv_free_ char **names = NULL;
bool enabled;
char **name;
}
static void systemctl_help(void) {
-
(void) pager_open(arg_no_pager, false);
printf("%s [OPTIONS...] {COMMAND} ...\n\n"
}
static int systemctl_parse_argv(int argc, char *argv[]) {
-
enum {
ARG_FAIL = 0x100,
ARG_REVERSE,
}
static int halt_parse_argv(int argc, char *argv[]) {
-
enum {
ARG_HELP = 0x100,
ARG_HALT,
}
static int shutdown_parse_argv(int argc, char *argv[]) {
-
enum {
ARG_HELP = 0x100,
ARG_NO_WALL
}
static int telinit_parse_argv(int argc, char *argv[]) {
-
enum {
ARG_HELP = 0x100,
ARG_NO_WALL
}
static int runlevel_parse_argv(int argc, char *argv[]) {
-
enum {
ARG_HELP = 0x100,
};
#if HAVE_SYSV_COMPAT
_pure_ static int action_to_runlevel(void) {
-
static const char table[_ACTION_MAX] = {
[ACTION_HALT] = '0',
[ACTION_POWEROFF] = '0',
}
static int systemctl_main(int argc, char *argv[]) {
-
static const Verb verbs[] = {
{ "list-units", VERB_ANY, VERB_ANY, VERB_DEFAULT|VERB_ONLINE_ONLY, list_units },
{ "list-unit-files", VERB_ANY, VERB_ANY, 0, list_unit_files },
}
static int reload_with_fallback(void) {
-
/* First, try systemd via D-Bus. */
if (daemon_reload(0, NULL, NULL) >= 0)
return 0;
}
static int start_with_fallback(void) {
-
/* First, try systemd via D-Bus. */
if (start_unit(0, NULL, NULL) >= 0)
return 0;
}
static int halt_now(enum action a) {
-
/* The kernel will automatically flush ATA disks and suchlike on reboot(), but the file systems need to be
* synce'd explicitly in advance. */
if (!arg_no_sync && !arg_dry_run)