Lines Matching defs:pos
485 unsigned int pos = session->position;
489 if (pos == 0)
492 if (pos < s->position_count && s->positions[pos] == session) {
493 s->positions[pos] = NULL;
499 if (iter->position == pos && session_get_state(iter) != SESSION_CLOSING) {
500 s->positions[pos] = iter;
507 void seat_claim_position(Seat *s, Session *session, unsigned int pos) {
510 pos = session->vtnr;
512 if (!GREEDY_REALLOC0(s->positions, s->position_count, pos + 1))
517 session->position = pos;
518 if (pos > 0)
519 s->positions[pos] = session;
523 unsigned int pos;
528 for (pos = 1; pos < s->position_count; ++pos)
529 if (!s->positions[pos])
532 seat_claim_position(s, session, pos);