Lines Matching refs:pw
156 struct passwd *pw; in load_user_database() local
176 while ((r = fgetpwent_sane(f, &pw)) > 0) { in load_user_database()
180 n = strdup(pw->pw_name); in load_user_database()
190 k = hashmap_put(database_by_username, n, UID_TO_PTR(pw->pw_uid)); in load_user_database()
194 q = hashmap_put(database_by_uid, UID_TO_PTR(pw->pw_uid), n); in load_user_database()
400 struct passwd *pw = NULL; in write_temporary_passwd() local
428 while ((r = fgetpwent_sane(original, &pw)) > 0) { in write_temporary_passwd()
429 i = ordered_hashmap_get(users, pw->pw_name); in write_temporary_passwd()
433 passwd_path, pw->pw_name); in write_temporary_passwd()
435 if (ordered_hashmap_contains(todo_uids, UID_TO_PTR(pw->pw_uid))) in write_temporary_passwd()
438 passwd_path, pw->pw_uid); in write_temporary_passwd()
441 if (IN_SET(pw->pw_name[0], '+', '-')) in write_temporary_passwd()
444 r = putpwent_sane(pw, passwd); in write_temporary_passwd()
447 pw->pw_name); in write_temporary_passwd()
493 pw->pw_name); in write_temporary_passwd()
497 while (pw) { in write_temporary_passwd()
498 r = putpwent_sane(pw, passwd); in write_temporary_passwd()
501 pw->pw_name); in write_temporary_passwd()
503 r = fgetpwent_sane(original, &pw); in write_temporary_passwd()