LightDM internally maintains a list of all users in the "system". This
is problematic when the user database is on a remote LDAP server and
contains thousands of users, because loading all of them can block
lightdm for minutes. This blocking seems to happen at least three times:
1) when lightdm daemon is started, 2) when a lightdm
child (seat/session?) is started and 3) when a user moves focus in the
greeter (gtk) from username to password field.
This patch eliminates long blocking by loading the users on
demand (using getpwnam() instead of getpwent()). The whole test suite
passes, but I'm afraid that some functionality could be broken. Feedback
welcome.