-/*-*- Mode: C; c-basic-offset: 8; indent-tabs-mode: nil -*-*/
-
+/* SPDX-License-Identifier: LGPL-2.1+ */
/***
This file is part of systemd.
#include "string-util.h"
#include "util.h"
-#ifndef RC_LOCAL_SCRIPT_PATH_START
-#define RC_LOCAL_SCRIPT_PATH_START "/etc/rc.d/rc.local"
-#endif
-
-#ifndef RC_LOCAL_SCRIPT_PATH_STOP
-#define RC_LOCAL_SCRIPT_PATH_STOP "/sbin/halt.local"
-#endif
-
-const char *arg_dest = "/tmp";
+static const char *arg_dest = "/tmp";
static int add_symlink(const char *service, const char *where) {
_cleanup_free_ char *from = NULL, *to = NULL;
assert(service);
assert(where);
- from = strjoin(SYSTEM_DATA_UNIT_PATH, "/", service, NULL);
+ from = strjoin(SYSTEM_DATA_UNIT_PATH, "/", service);
if (!from)
return log_oom();
- to = strjoin(arg_dest, "/", where, ".wants/", service, NULL);
+ to = strjoin(arg_dest, "/", where, ".wants/", service);
if (!to)
return log_oom();
if (errno == EEXIST)
return 0;
- log_error_errno(errno, "Failed to create symlink %s: %m", to);
- return -errno;
+ return log_error_errno(errno, "Failed to create symlink %s: %m", to);
}
return 1;