From fde78a3ac01db57a384e5936bf2c033dcdeae494 Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Tue, 28 Jun 2011 23:21:43 +0200 Subject: [PATCH] logind: fix generation of seat state file --- src/logind-seat.c | 13 +++---------- 1 file changed, 3 insertions(+), 10 deletions(-) diff --git a/src/logind-seat.c b/src/logind-seat.c index 11b3a65b..5663aeea 100644 --- a/src/logind-seat.c +++ b/src/logind-seat.c @@ -117,27 +117,20 @@ int seat_save(Seat *s) { if (s->sessions) { Session *i; - fputs("OTHER=", f); + fputs("SESSIONS=", f); LIST_FOREACH(sessions_by_seat, i, s->sessions) { - if (i == s->active) - continue; - fprintf(f, "%s%c", i->id, i->sessions_by_seat_next ? ' ' : '\n'); } - fputs("OTHER_UIDS=", f); - LIST_FOREACH(sessions_by_seat, i, s->sessions) { - if (i == s->active) - continue; - + fputs("UIDS=", f); + LIST_FOREACH(sessions_by_seat, i, s->sessions) fprintf(f, "%lu%c", (unsigned long) i->user->uid, i->sessions_by_seat_next ? ' ' : '\n'); - } } fflush(f); -- 2.39.5