GNU bug report logs -
#31446
26.1; sql-interactive-mode buffer naming is broken
Previous Next
Reported by: Phil Sainty <psainty <at> orcon.net.nz>
Date: Mon, 14 May 2018 05:56:02 UTC
Severity: normal
Found in version 26.1
Done: Michael Mauger <mmauger <at> protonmail.com>
Bug is archived. No further changes may be made.
Full log
Message #11 received at 31446 <at> debbugs.gnu.org (full text, mbox):
> Date: Fri, 18 May 2018 12:49:28 +0300
> From: Eli Zaretskii <eliz <at> gnu.org>
> Cc: 31446 <at> debbugs.gnu.org
>
> does the patch below give good results?
Sorry, that patch left out an important use case. Please try the one
below.
(Is it correct to use "*SQL*" when no prefix arg is given?)
diff --git a/lisp/progmodes/sql.el b/lisp/progmodes/sql.el
index e4db6cc..2ced15c 100644
--- a/lisp/progmodes/sql.el
+++ b/lisp/progmodes/sql.el
@@ -4263,9 +4263,18 @@ sql-product-interactive
(funcall (sql-get-product-feature product :sqli-comint-func)
product
(sql-get-product-feature product :sqli-options)
- (if (and new-name (string-prefix-p "SQL" new-name t))
- new-name
- (concat "SQL: " new-name))))
+ (cond
+ ((zerop new-name)
+ "*SQL*")
+ ((stringp new-name)
+ (if (string-prefix-p "SQL" new-name t)
+ new-name
+ (concat "*SQL: " new-name "*")))
+ ((eq new-name '(4))
+ (sql-rename-buffer new-name)
+ sql-alternate-buffer-name)
+ (t
+ (format "*SQL: %s*" new-name)))))
;; Set SQLi mode.
(let ((sql-interactive-product product))
This bug report was last modified 6 years and 25 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.