From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#55883: [PATCH] Update X Primary Selection with active regions Date: Wed, 15 Jun 2022 19:51:10 +0300 Message-ID: <83v8t1rhtt.fsf@gnu.org> References: <834k0t104u.fsf@gnu.org> <8335gbzled.fsf@gnu.org> <837d5jtp9x.fsf@gnu.org> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="32406"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 55883@debbugs.gnu.org To: Duncan Findlay Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Jun 15 18:52:49 2022 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1o1WG8-0008Eu-Ug for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 15 Jun 2022 18:52:49 +0200 Original-Received: from localhost ([::1]:54120 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1o1WG7-0008D0-UA for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 15 Jun 2022 12:52:47 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:57526) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1o1WFO-0008AT-IS for bug-gnu-emacs@gnu.org; Wed, 15 Jun 2022 12:52:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:45820) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1o1WFO-0002YN-7b for bug-gnu-emacs@gnu.org; Wed, 15 Jun 2022 12:52:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1o1WFO-00019v-6S for bug-gnu-emacs@gnu.org; Wed, 15 Jun 2022 12:52:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 15 Jun 2022 16:52:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 55883 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 55883-submit@debbugs.gnu.org id=B55883.16553119214441 (code B ref 55883); Wed, 15 Jun 2022 16:52:02 +0000 Original-Received: (at 55883) by debbugs.gnu.org; 15 Jun 2022 16:52:01 +0000 Original-Received: from localhost ([127.0.0.1]:39716 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1o1WFL-00019X-5K for submit@debbugs.gnu.org; Wed, 15 Jun 2022 12:52:01 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:44164) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1o1WFG-000192-4y for 55883@debbugs.gnu.org; Wed, 15 Jun 2022 12:51:57 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:39198) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1o1WEy-0002Lu-T0; Wed, 15 Jun 2022 12:51:48 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=J5rbngz4Y2vCNIVgUvGhOuRSTBorvtREF56BnRbLc3k=; b=PVvLJzC7BuS2 i8e7AU9uueSulBvWFd5rYr9ObEHQ/v6ZvLmpkOmr9OgcOlaymuMBULsP0ufy+/p113j1bwQ3aQPBC cW72LA6yK4BmosfAL4eZYxOQ070cLWQ/tCPV/HeSU1n7EhQSGHMKUAfkmc/Yy58ODlaQHVQqS647G +lEhBWR9rWsNkJSn4dknH+5NanqpyiVMAA1rP6BAUwhtluaM5ESyJFRyPtbnwAYCOEWsYeTKZqO9C o4Nh5QdjPAbdHD3lI4SoH7Z9ba8/dxvsxg2Rokz1ikqxGUKmUZpmXhpwaGbAB0qpoyG8pxL51R+zK rtgG5dCeIDskFpOycJwagg==; Original-Received: from [87.69.77.57] (port=4201 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1o1WEf-0001vH-U4; Wed, 15 Jun 2022 12:51:21 -0400 In-Reply-To: (message from Duncan Findlay on Tue, 14 Jun 2022 19:01:58 -0700) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:234596 Archived-At: > From: Duncan Findlay > Date: Tue, 14 Jun 2022 19:01:58 -0700 > Cc: 55883@debbugs.gnu.org > > > > !NILP (SYMBOL_VAL (XSYMBOL (Qxterm_select_active_regions))) > > > > This is not safe, IMO. I think this is better: > > > > if ((!NILP (Fwindow_system (Qnil)) > > || ((symval = find_symbol_value (Qxterm_select_active_regions), > > (!EQ (symval, Qunbound) && !NILP (symval))) > > && !NILP (Fterminal_parameter (Qnil, Qxterm__set_selection)))) > > Thanks, I would never have figured that out myself. That's what we are here for (one reason, at least). > > > I've also addressed Po's comments about long conditionals. > > > > Thanks, the patch LGTM, modulo the above 2 minor nits. This version LGTM, I will install soon, unless someone comes up with more comments.