From 207d1d0922d4e668cc6fac98be39e5a8b83ebc8a Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Fri, 13 Dec 2013 20:36:02 +0100 Subject: getty-generator: fix segfault when $container_ttys is not set --- src/getty-generator/getty-generator.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/getty-generator/getty-generator.c b/src/getty-generator/getty-generator.c index 36a93695fb..feb58156ea 100644 --- a/src/getty-generator/getty-generator.c +++ b/src/getty-generator/getty-generator.c @@ -130,7 +130,7 @@ int main(int argc, char *argv[]) { * the variable name we only support ptys here. */ r = getenv_for_pid(1, "container_ttys", &container_ttys); - if (r >= 0) { + if (r > 0) { char *w, *state; size_t l; -- cgit v1.2.3-54-g00ecf