]> git.eshelyaron.com Git - emacs.git/commitdiff
Fix Bug#32107
authorFilipp Gunbin <fgunbin@fastmail.fm>
Wed, 11 Jul 2018 02:28:21 +0000 (05:28 +0300)
committerFilipp Gunbin <fgunbin@fastmail.fm>
Wed, 11 Jul 2018 02:30:10 +0000 (05:30 +0300)
* lisp/progmodes/sql.el (sql-buffer-live-p): Fix handling of optional
  connection argument.  (Bug#32107)

lisp/progmodes/sql.el

index 223fb2ec9365b98356bf513d5b59f74ffd90871f..ba180c2b26c8f0e1bd088fe983717330608f93a6 100644 (file)
@@ -1270,8 +1270,9 @@ specified, it's `sql-product' or `sql-connection' must match."
            (and (derived-mode-p 'sql-interactive-mode)
                 (or (not product)
                     (eq product sql-product))
-                (or (stringp connection)
-                    (string= connection sql-connection)))))))
+                (or (not connection)
+                    (and (stringp connection)
+                         (string= connection sql-connection))))))))
 
 ;; Keymap for sql-interactive-mode.