TRACE(("XStoreBuffer(%d)\n", cutbuffer));
_OwnSelection(XtermWidget termw,	      String * selections,	      Cardinal count){    Atom *atoms = termw->screen.selection_atoms;    Cardinal i;    Boolean have_selection = False;    if (termw->screen.selection_length < 0)	return;    if (count > termw->screen.sel_atoms_size) {	XtFree((char *) atoms);	atoms = (Atom *) XtMalloc(count * sizeof(Atom));	termw->screen.selection_atoms = atoms;	termw->screen.sel_atoms_size = count;    }    XmuInternStrings(XtDisplay((Widget) termw), selections, count, atoms);    for (i = 0; i < count; i++) {	int cutbuffer;	switch (atoms[i]) {	case XA_CUT_BUFFER0:	    cutbuffer = 0;	    break;	case XA_CUT_BUFFER1:	    cutbuffer = 1;	    break;	case XA_CUT_BUFFER2:	    cutbuffer = 2;	    break;	case XA_CUT_BUFFER3:	    cutbuffer = 3;	    break;	case XA_CUT_BUFFER4:	    cutbuffer = 4;	    break;	case XA_CUT_BUFFER5:	    cutbuffer = 5;	    break;	case XA_CUT_BUFFER6:	    cutbuffer = 6;	    break;	case XA_CUT_BUFFER7:	    cutbuffer = 7;	    break;	default:	    cutbuffer = -1;	}	if (cutbuffer >= 0) {	    if (termw->screen.selection_length >		4 * XMaxRequestSize(XtDisplay((Widget) termw)) - 32) {		fprintf(stderr,			"%s: selection too big (%d bytes), not storing in CUT_BUFFER%d\n",			xterm_name, termw->screen.selection_length, cutbuffer);	    } else {		/* This used to just use the UTF-8 data, which was totally		 * broken as not even the corresponding paste code in Xterm		 * understood this!  So now it converts to Latin1 first.		 *   Robert Brady, 2000-09-05		 */		unsigned long length = termw->screen.selection_length;		Char *data = (Char *) termw->screen.selection_data;		if_OPT_WIDE_CHARS((&(termw->screen)), {		    data = UTF8toLatin1(data, length, &length);		});		XStoreBuffer(XtDisplay((Widget) termw),			     (char *) data, length, cutbuffer);	    }	} else if (!replyToEmacs) {	    have_selection |=		XtOwnSelection((Widget) termw, atoms[i],			       termw->screen.selection_time,			       ConvertSelection, LoseSelection, SelectionDone);	}    }