From: Christian Brauner Date: Thu, 29 Jul 2021 12:15:51 +0000 (+0200) Subject: conf: use a relative path in symlinkat() X-Git-Tag: lxc-5.0.0~130^2~4 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=068534278ed42f05e7deac342abedc8ba9a451c9;p=thirdparty%2Flxc.git conf: use a relative path in symlinkat() Signed-off-by: Christian Brauner --- diff --git a/src/lxc/conf.c b/src/lxc/conf.c index c6c9397e2..488ae7d5c 100644 --- a/src/lxc/conf.c +++ b/src/lxc/conf.c @@ -1830,7 +1830,7 @@ static int lxc_finalize_devpts_child(struct lxc_handler *handler) return log_error_errno(-1, errno, "Failed to remove existing \"/dev/ptmx\""); /* Fallback option: Create symlink /dev/ptmx -> /dev/pts/ptmx. */ - ret = symlinkat("/dev/pts/ptmx", rootfs->dfd_dev, "/dev/ptmx"); + ret = symlinkat("/dev/pts/ptmx", rootfs->dfd_dev, "dev/ptmx"); if (ret < 0) return log_error_errno(-1, errno, "Failed to create symlink from \"/dev/ptmx\" to \"/dev/pts/ptmx\"");