--- rxvt-unicode/src/screen.C 2011/01/28 00:08:58 1.366 +++ rxvt-unicode/src/screen.C 2011/01/31 15:40:22 1.367 @@ -2744,24 +2744,21 @@ { if (prop == None) /* check for failed XConvertSelection */ { + int selnum = selection_type & Sel_whereMask; + + if (selnum == Sel_direct) + selection_type = 0; + if ((selection_type & Sel_CompoundText)) { - int selnum = selection_type & Sel_whereMask; - selection_type = 0; - if (selnum != Sel_direct) - selection_request_other (XA_STRING, selnum); + selection_request_other (XA_STRING, selnum); } if ((selection_type & Sel_UTF8String)) { - int selnum = selection_type & Sel_whereMask; - selection_type = Sel_CompoundText; - if (selnum != Sel_direct) - selection_request_other (xa[XA_COMPOUND_TEXT], selnum); - else - selection_type = 0; + selection_request_other (xa[XA_COMPOUND_TEXT], selnum); } return;