]> git.eshelyaron.com Git - emacs.git/commitdiff
Another attempt to fix sql.el
authorEli Zaretskii <eliz@gnu.org>
Mon, 21 May 2018 15:43:03 +0000 (18:43 +0300)
committerEli Zaretskii <eliz@gnu.org>
Mon, 21 May 2018 15:43:03 +0000 (18:43 +0300)
* lisp/progmodes/sql.el (sql-product-interactive): Fix calculation
of the SQL buffer name.  (Bug#31446)

lisp/progmodes/sql.el

index 1b2cdaf5f60002249e57791f2b7ba451e3693139..e7d7494d2cae7661187afc2a267ef2aad3c08df0 100644 (file)
@@ -4270,8 +4270,13 @@ the call to \\[sql-product-interactive] with
                            (if (string-prefix-p "*SQL: " new-name t)
                                new-name
                              (concat "*SQL: " new-name "*")))
-                          ((eq new-name '(4))
-                           (sql-rename-buffer new-name))
+                          ((equal new-name '(4))
+                           (concat
+                            "*SQL: "
+                            (read-string
+                             "Buffer name (\"*SQL: XXX*\"; enter `XXX'): "
+                             sql-alternate-buffer-name)
+                            "*"))
                           (t
                            (format "*SQL: %s*" new-name)))))