diff --git a/libweston/weston-launch.c b/libweston/weston-launch.c index aa7e0711..dcd31e1a 100644 --- a/libweston/weston-launch.c +++ b/libweston/weston-launch.c @@ -722,6 +722,9 @@ main(int argc, char *argv[]) if ((argc - optind) > (MAX_ARGV_SIZE - 6)) error(1, E2BIG, "Too many arguments to pass to weston"); + if (tty && !wl.new_user) + error(1, 0, "-t/--tty option requires -u/--user option as well"); + if (wl.new_user) wl.pw = getpwnam(wl.new_user); else