From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Po Lu via "Bug reports for GNU Emacs, the Swiss army knife of text editors" Newsgroups: gmane.emacs.bugs Subject: bug#56372: 29.0.50; [PATCH] Avoid BadMatch X11 error Date: Mon, 04 Jul 2022 09:16:12 +0800 Message-ID: <87y1x9u17n.fsf@yahoo.com> References: <87czemtfv0.fsf@dick> Reply-To: Po Lu Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="23406"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.91 (gnu/linux) Cc: 56372@debbugs.gnu.org To: dick.r.chiang@gmail.com Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Mon Jul 04 03:17:20 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 1o8AiG-0005ss-9r for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 04 Jul 2022 03:17:20 +0200 Original-Received: from localhost ([::1]:54984 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1o8AiE-0003g4-RN for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 03 Jul 2022 21:17:18 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:52270) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1o8Ahy-0003fs-Tx for bug-gnu-emacs@gnu.org; Sun, 03 Jul 2022 21:17:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:51797) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1o8Ahy-0002Rr-LM for bug-gnu-emacs@gnu.org; Sun, 03 Jul 2022 21:17:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1o8Ahy-0007ES-G0 for bug-gnu-emacs@gnu.org; Sun, 03 Jul 2022 21:17:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Po Lu Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 04 Jul 2022 01:17:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 56372 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 56372-submit@debbugs.gnu.org id=B56372.165689739427760 (code B ref 56372); Mon, 04 Jul 2022 01:17:02 +0000 Original-Received: (at 56372) by debbugs.gnu.org; 4 Jul 2022 01:16:34 +0000 Original-Received: from localhost ([127.0.0.1]:45694 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1o8AhW-0007Df-2f for submit@debbugs.gnu.org; Sun, 03 Jul 2022 21:16:34 -0400 Original-Received: from sonic309-22.consmr.mail.ne1.yahoo.com ([66.163.184.148]:42039) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1o8AhS-0007DO-BV for 56372@debbugs.gnu.org; Sun, 03 Jul 2022 21:16:33 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1656897384; bh=qOOGWEHEvzXv6BHX/xeoY1qrHTQ2F6B0KfI1MUOvk4E=; h=From:To:Cc:Subject:References:Date:In-Reply-To:From:Subject:Reply-To; b=C0LW3MkBcyHhXXv9SlwSigEiN1H4lhdPwbabzvZ9KeXRdD1Gu5VZm/j3DFS0LSQRZen1OHt0IIXsd0myqH7P1Cz9vodRG/UoaBSpSeHxp1+jhbiIULQIeOR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EXc9ruhtP91nhrgFwE2V.hkFRERD0gv dUt5qHM5QgA7__aTe4fuj3250832G_Ambsm55YmUc8_OMpCmA74whOtsq5iSGtsWR7GELrDubUGE dQwzBfK3zjmyPxaUl6KN2AML5iJCR.EFdv34qvkH.Pr_p2oheIt6d.M91SyU3N0jFwSir_LqyFkt 8CKMG.kHqb5Mhp21Xph6PCYqpWfkvB7ihUOv_nQcEtibhjaGmpsMbCKIcLlX18cQw3IFd8kYJnA. Jw7awvpYskNgw6lrdk1qixZPKluCtpRNHIFgkdu_uhtMOUJNhC7VA5rciHEb1JVY6Kn.D5m7RfiJ MlsHSq3STYB9SkVP2pACefGpZc2cwoLbGf.ToN3FoqeTexh9eCu3SDnHaDyJrkhgbtT3kbZ20m4K ifUb6dtUcPB3HiZV8_6Cr8yLEMrWvn5JWCPN_T7YFKKpvG3iP3PcL5nu.S4H3zB.41lU1nKuzef2 6c5TiG0COTLFBd5gMw3PnCEPufej_h._XX0YVO7kro X-Sonic-MF: Original-Received: from sonic.gate.mail.ne1.yahoo.com by sonic309.consmr.mail.ne1.yahoo.com with HTTP; Mon, 4 Jul 2022 01:16:24 +0000 Original-Received: by hermes--canary-production-sg3-67975bbd4b-zlmw9 (Yahoo Inc. Hermes SMTP Server) with ESMTPA ID 5348ec4dfea8dc474c40a8a5ba2bee72; Mon, 04 Jul 2022 01:16:17 +0000 (UTC) In-Reply-To: <87czemtfv0.fsf@dick> (dick r. chiang's message of "Sun, 03 Jul 2022 10:45:07 -0400") X-Mailer: WebService/1.1.20381 mail.backend.jedi.jws.acl:role.jedi.acl.token.atz.jws.hermes.yahoo 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:236029 Archived-At: dick.r.chiang@gmail.com writes: > With my particular font sizing, I get an X11 BadMatch (invalid parameter > attributes) error one out of every 10 starts or so. > >>>From 95911e85c12e91123ebc4448700f67877b4109cc Mon Sep 17 00:00:00 2001 > From: dickmao > Date: Sun, 3 Jul 2022 10:34:20 -0400 > Subject: [PATCH] Avoid a BadMatch X11 error > > x_uncatch_errors() might do a sync that > x_ignore_errors_for_next_request() doesn't? The details are unclear. Where is the error, and what request is generating it? The X server reports errors asynchronously, the next time Xlib or Emacs calls XSync after the erroring request is made. x_ignore_errors_for_next_request and x_stop_ignoring_errors don't call XSync (unlike the usual error handling and checking functions) -- they only make a note of the range of requests made inside them, so the x_error_handler knows that it should ignore the error. This is done for speed, since syncing is slow, especially over connections with high latency. So assuming the erroring request is actually XSetWindowBorder, please see why x_error_handler is actually not ignoring the error. The useless reformatting of code in xfaces.c, is, as usual for patches from you, unacceptable.