Lines Matching refs:typ
498 struct ttyent *typ; in f_single_user() local
528 typ = getttynam("console"); in f_single_user()
530 if (typ && (typ->ty_status & TTY_SECURE) == 0 && pp && in f_single_user()
836 new_session(session_t *sprev, int session_index, struct ttyent *typ) in new_session() argument
840 if ((typ->ty_status & TTY_ON) == 0 || in new_session()
841 typ->ty_name == 0 || in new_session()
842 typ->ty_getty == 0) in new_session()
852 if (asprintf(&sp->se_device, "%s%s", _PATH_DEV, typ->ty_name) == -1) in new_session()
855 if (setupargv(sp, typ) == 0) { in new_session()
876 setupargv(session_t *sp, struct ttyent *typ) in setupargv() argument
882 if (asprintf(&sp->se_getty, "%s %s", typ->ty_getty, typ->ty_name) == -1) in setupargv()
891 if (typ->ty_window) { in setupargv()
893 sp->se_window = strdup(typ->ty_window); in setupargv()
918 struct ttyent *typ; in f_read_ttys() local
936 while ((typ = getttyent())) in f_read_ttys()
937 if ((snext = new_session(sp, ++session_index, typ))) in f_read_ttys()
1192 struct ttyent *typ; in f_clean_ttys() local
1200 while ((typ = getttyent())) { in f_clean_ttys()
1204 if (strcmp(typ->ty_name, sp->se_device + devlen) == 0) in f_clean_ttys()
1215 if ((typ->ty_status & TTY_ON) == 0 || in f_clean_ttys()
1216 typ->ty_getty == 0) { in f_clean_ttys()
1222 if (setupargv(sp, typ) == 0) { in f_clean_ttys()
1231 new_session(sprev, session_index, typ); in f_clean_ttys()