Avoid using variable before it has been initialized
* lisp/ibuffer.el (ibuffer-shrink-to-fit): Don't try to use ibuffer-auto-mode variable before ibuf-ext.el has been loaded. (Bug#51029)
This commit is contained in:
parent
b2c50d7cf3
commit
ead5c5cc51
1 changed files with 2 additions and 1 deletions
|
@ -1079,7 +1079,8 @@ a new window in the current frame, splitting vertically."
|
||||||
;; Make sure that redisplay is performed, otherwise there can be a
|
;; Make sure that redisplay is performed, otherwise there can be a
|
||||||
;; bad interaction with code in the window-scroll-functions hook
|
;; bad interaction with code in the window-scroll-functions hook
|
||||||
(redisplay t)
|
(redisplay t)
|
||||||
(when (buffer-local-value 'ibuffer-auto-mode (window-buffer))
|
(when (and (boundp 'ibuffer-auto-mode) ; ibuf-ext.el might not be loaded yet
|
||||||
|
(buffer-local-value 'ibuffer-auto-mode (window-buffer)))
|
||||||
(fit-window-to-buffer
|
(fit-window-to-buffer
|
||||||
nil (and owin
|
nil (and owin
|
||||||
(/ (frame-height)
|
(/ (frame-height)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue