Lines Matching refs:ut
1345 struct utmpx ut;
1348 (void)memset(&ut, 0, sizeof(ut));
1349 (void)strlcpy(ut.ut_name, name, sizeof(ut.ut_name));
1350 ut.ut_type = type;
1351 (void)strlcpy(ut.ut_line, line, sizeof(ut.ut_line));
1352 ut.ut_pid = pid;
1354 ut.ut_tv = *tv;
1356 (void)gettimeofday(&ut.ut_tv, NULL);
1357 ut.ut_session = session;
1360 if ((size_t)(eline - line) >= sizeof(ut.ut_id))
1361 line = eline - sizeof(ut.ut_id);
1362 (void)strncpy(ut.ut_id, line, sizeof(ut.ut_id));
1364 if (pututxline(&ut) == NULL)
1365 warning("can't add utmpx record for `%s': %m", ut.ut_line);
1390 struct utmpx ut;
1400 (void)memset(&ut, 0, sizeof(ut));
1401 (void)snprintf(ut.ut_line, sizeof(ut.ut_line), RUNLVL_MSG, new);
1402 ut.ut_type = RUN_LVL;
1403 (void)gettimeofday(&ut.ut_tv, NULL);
1404 ut.ut_exit.e_exit = old;
1405 ut.ut_exit.e_termination = new;
1406 if (pututxline(&ut) == NULL)