From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Filipp Gunbin Newsgroups: gmane.emacs.bugs Subject: bug#31446: 26.1; sql-interactive-mode buffer naming is broken Date: Fri, 18 May 2018 21:03:00 +0300 Message-ID: References: <83d0xti993.fsf@gnu.org> <83bmddi2ad.fsf@gnu.org> <83603lhrvw.fsf@gnu.org> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1526666534 8674 195.159.176.226 (18 May 2018 18:02:14 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Fri, 18 May 2018 18:02:14 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (darwin) Cc: psainty@orcon.net.nz, 31446@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri May 18 20:02:09 2018 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fJjhg-00027r-VE for geb-bug-gnu-emacs@m.gmane.org; Fri, 18 May 2018 20:02:09 +0200 Original-Received: from localhost ([::1]:40337 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fJjjo-0001XY-0i for geb-bug-gnu-emacs@m.gmane.org; Fri, 18 May 2018 14:04:20 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:44940) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fJjja-0001Up-CM for bug-gnu-emacs@gnu.org; Fri, 18 May 2018 14:04:08 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fJjjW-0002iK-AH for bug-gnu-emacs@gnu.org; Fri, 18 May 2018 14:04:06 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:60407) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fJjjW-0002iE-6P for bug-gnu-emacs@gnu.org; Fri, 18 May 2018 14:04:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1fJjjV-0000Ja-Pl for bug-gnu-emacs@gnu.org; Fri, 18 May 2018 14:04:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Filipp Gunbin Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 18 May 2018 18:04:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 31446 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 31446-submit@debbugs.gnu.org id=B31446.15266665861152 (code B ref 31446); Fri, 18 May 2018 18:04:01 +0000 Original-Received: (at 31446) by debbugs.gnu.org; 18 May 2018 18:03:06 +0000 Original-Received: from localhost ([127.0.0.1]:40071 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fJjic-0000IW-A9 for submit@debbugs.gnu.org; Fri, 18 May 2018 14:03:06 -0400 Original-Received: from out1-smtp.messagingengine.com ([66.111.4.25]:57801) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fJjiZ-0000IN-RS for 31446@debbugs.gnu.org; Fri, 18 May 2018 14:03:04 -0400 Original-Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id 54181225C6; Fri, 18 May 2018 14:03:03 -0400 (EDT) Original-Received: from mailfrontend1 ([10.202.2.162]) by compute1.internal (MEProxy); Fri, 18 May 2018 14:03:03 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fastmail.fm; h= cc:content-type:date:from:in-reply-to:message-id:mime-version :references:subject:to:x-me-sender:x-me-sender:x-sasl-enc; s= fm3; bh=KO42m46bew3rL5oej9T0AE3bgagFvFmLndVlLlUaiA8=; b=L5blqGbC ZMmebmkuY42Am0e+K5tr8YZ6EckQfRFcg6eQdS2sJLubg0ffk3x+w7Qnc0VLqK1r 3nQth93pI4rlO9yoPzG3m1L8ICeLqJ/AF2cMhnLvAYzyR9dMEGm80h9V5mY4tJEu qUUJkgprWJhnUpVUotMRMbFpC9cII1VIeawsqkUwH5qt7NiRLtJ0wil7L7ybJOI/ Vdbc5X6X/e/DSrv5hAjyhwlHCzrMlrHsfsyrI0x7/6LGjE61XFLbdsX2Ixia/83Q +5rioetbys9ydX3rTn9unN86gJruvu1QzOVEAn7X3SqldSCe14C/1c/w8MZPdKfR i8aW+XoCxoBwog== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-sender :x-me-sender:x-sasl-enc; s=fm2; bh=KO42m46bew3rL5oej9T0AE3bgagFv FmLndVlLlUaiA8=; b=fb6I2xSMxeZnMCjW+/q4sliX3g+7/LUYqdUUTrV+Vot71 oOpJK5GLfVp1WV4v3/c/ONdmiZWXULumURxnjXLxCYUZFAE89MhbKSihtfOh/TA4 +xUN53hSE0qGJUYETnJAWRFLN/J5dk2HpVoGN14Py/ClwFD9x3beB7NBzOCUc4Y+ 2EM0BH0TugS0q9Qj6nHs+JkHzHtZp8jEdZ+7DnBgLjmffI3z96PnfaGh10oCZaXz QPJ6MuSxmBZyaRk3/izw/6qdOEgNF/x+9ckPj2NUft1/GVssLm9gd2wmiDEbF/DS xJCjM9eFEU3a8YXqIRCRgtISJu4QfqwNQj/CbiasA== X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Sender: Original-Received: from fgunbin.playteam.ru (unknown [94.25.218.10]) by mail.messagingengine.com (Postfix) with ESMTPA id 6098CE43C8; Fri, 18 May 2018 14:03:02 -0400 (EDT) In-Reply-To: <83603lhrvw.fsf@gnu.org> (Eli Zaretskii's message of "Fri, 18 May 2018 19:04:35 +0300") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 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.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:146270 Archived-At: On 18/05/2018 19:04 +0300, Eli Zaretskii wrote: >> From: Filipp Gunbin >> Cc: psainty@orcon.net.nz, 31446@debbugs.gnu.org >> Date: Fri, 18 May 2018 18:44:38 +0300 >> >> But `sql-comint' (called from `sql-comint-postgres' and the like) has >> logic which prepares buffer name (adding those asterisks etc.) >> >> In `sql-product-interactive', `new-name', if set to '(4) from prefix, or >> to some other value from argument, controls this: >> >> (if (and (not new-name) buf) >> (pop-to-buffer buf) >> >> So if `new-name' is set, we shouldn't switch to existing buffer. > > I'm sorry, but I don't understand the issue you are alluding to. The > bug I tried to fix was that the buffer got named incorrectly. Is that > fixed by the patch? If it isn't, please tell why. > > If the patch does fix the bug, then the issues you mention are > separate problems, because I don't think I changed the logic of which > buffer is going to become the current. > > What am I missing? I was trying to say that probably this function should not mess with the buffer name at all. Your patch, while it may have fixed the bug, introduces some logic on setting buffer name - so we could get undesired behaviour change. While a simpler approach would be just to pass `new-name' like I proposed. I'm not the person who filed this bug, but I also suffer from sqli-mode buffers naming problem :-) Sorry if it's actually me who's missing something. Filipp