luni_send(term->paste_buffer + term->paste_pos, n, 0);
if (term->ldisc) luni_send(term->ldisc, term->paste_buffer + term->paste_pos, n, 0);
void term_paste(Terminal *term){    long now, paste_diff;    if (term->paste_len == 0)	return;    /* Don't wait forever to paste */    if (term->paste_hold) {	now = GETTICKCOUNT();	paste_diff = now - term->last_paste;	if (paste_diff >= 0 && paste_diff < 450)	    return;    }    term->paste_hold = 0;    while (term->paste_pos < term->paste_len) {	int n = 0;	while (n + term->paste_pos < term->paste_len) {	    if (term->paste_buffer[term->paste_pos + n++] == '\r')		break;	}	luni_send(term->paste_buffer + term->paste_pos, n, 0);	term->paste_pos += n;	if (term->paste_pos < term->paste_len) {	    term->paste_hold = 1;	    return;	}    }    sfree(term->paste_buffer);    term->paste_buffer = NULL;    term->paste_len = 0;}