[systemd-commits] src/getty-generator

Kay Sievers kay at kemper.freedesktop.org
Sun Dec 2 09:19:08 PST 2012


 src/getty-generator/getty-generator.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit a705d08519d26cd2ee581cd04cb70888b3a55b62
Author: David Herrmann <dh.herrmann at googlemail.com>
Date:   Sun Dec 2 18:06:35 2012 +0100

    getty-generator: fix handling systems without a console
    
    If the system does not have any active console, we should not try to
    create an empty symlink. Instead, create no symlink at all.
    
    Otherwise, on systems with CONFIG_VT=n and no serial console, we will
    create a symlink with an empty template parameter.

diff --git a/src/getty-generator/getty-generator.c b/src/getty-generator/getty-generator.c
index 1cef6ae..cb38f21 100644
--- a/src/getty-generator/getty-generator.c
+++ b/src/getty-generator/getty-generator.c
@@ -131,7 +131,7 @@ int main(int argc, char *argv[]) {
 
                 /* Automatically add in a serial getty on the kernel
                  * console */
-                if (tty_is_vc(tty))
+                if (isempty(tty) || tty_is_vc(tty))
                         free(active);
                 else {
                         int k;



More information about the systemd-commits mailing list