Subject: bug#45848: 27.1; Buffers menu opens wrong buffer

From: "Joseph Coffland" <[email-masked]>
Date: Wed, 13 Jan 2021 15:13:17 -0800

In recent versions of GTK Emacs with multiple frames open, selecting the
top buffer from the Buffers menu often opens the wrong buffer.  Upon
returning to the Buffers menu, the top item has changed to the one that
actually opened.  Selecting the desired file from the menu again opens the
correct file as expected.

The Buffers menu on each frame appears to be the same but in reality the
order is different.  When one frame is in focus but you click on the
Buffers menu of an unfocused frame it will show the Buffers for the
focused menu.  If you close the menu and reclick, the focus will have
changed and it will show the correct Buffers menu.

I belive the problem is that the Buffers menu opens before the frame focus
changes causing the wrong Buffers list to display for the frame.

Thanks,

Joseph

Configured features:
XPM JPEG TIFF GIF PNG RSVG CAIRO SOUND GPM DBUS GSETTINGS GLIB NOTIFY
INOTIFY ACL LIBSELINUX GNUTLS LIBXML2 FREETYPE HARFBUZZ M17N_FLT LIBOTF
ZLIB TOOLKIT_SCROLL_BARS GTK3 X11 XDBE XIM MODULES THREADS LIBSYSTEMD
JSON PDUMPER LCMS2 GMP

Important settings:
  value of $LANG: en_US.UTF-8
  value of $XMODIFIERS: @im=ibus
  locale-coding-system: utf-8-unix

Major mode: C++//

Minor modes in effect:
  shell-dirtrack-mode: t
  fci-mode: t
  modern-c++-font-lock-global-mode: t
  modern-c++-font-lock-mode: t
  global-flycheck-mode: t
  flycheck-mode: t
  global-whitespace-mode: t
  save-place-mode: t
  global-auto-revert-mode: t
  tooltip-mode: t
  global-eldoc-mode: t
  mouse-wheel-mode: t
  tool-bar-mode: t
  menu-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  blink-cursor-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  column-number-mode: t
  line-number-mode: t
  abbrev-mode: t

Load-path shadows:
~/.emacs.d/site-lisp/markdown-mode hides
/usr/share/emacs/site-lisp/elpa/markdown-mode-2.4/markdown-mode
/usr/share/emacs/site-lisp/elpa/dash-2.17.0/dash hides
/usr/share/emacs/site-lisp/elpa-src/dash-2.17.0/dash
/usr/share/emacs/site-lisp/elpa/dash-2.17.0/dash-autoloads hides
/usr/share/emacs/site-lisp/elpa-src/dash-2.17.0/dash-autoloads
/usr/share/emacs/site-lisp/elpa/dash-2.17.0/dash-pkg hides
/usr/share/emacs/site-lisp/elpa-src/dash-2.17.0/dash-pkg
/usr/share/emacs/site-lisp/elpa/epl-0.9/epl-autoloads hides
/usr/share/emacs/site-lisp/elpa-src/epl-0.9/epl-autoloads
/usr/share/emacs/site-lisp/elpa/epl-0.9/epl hides
/usr/share/emacs/site-lisp/elpa-src/epl-0.9/epl
/usr/share/emacs/site-lisp/elpa/epl-0.9/epl-pkg hides
/usr/share/emacs/site-lisp/elpa-src/epl-0.9/epl-pkg
/usr/share/emacs/site-lisp/elpa/fill-column-indicator-1.90/fill-column-indicator-pkg
hides
/usr/share/emacs/site-lisp/elpa-src/fill-column-indicator-1.90/fill-column-indicator-pkg
/usr/share/emacs/site-lisp/elpa/fill-column-indicator-1.90/fill-column-indicator-autoloads
hides
/usr/share/emacs/site-lisp/elpa-src/fill-column-indicator-1.90/fill-column-indicator-autoloads
/usr/share/emacs/site-lisp/elpa/fill-column-indicator-1.90/fill-column-indicator
hides
/usr/share/emacs/site-lisp/elpa-src/fill-column-indicator-1.90/fill-column-indicator
/usr/share/emacs/site-lisp/elpa/flycheck-32snapshot/flycheck-autoloads
hides
/usr/share/emacs/site-lisp/elpa-src/flycheck-32snapshot/flycheck-autoloads
/usr/share/emacs/site-lisp/elpa/flycheck-32snapshot/flycheck-pkg hides
/usr/share/emacs/site-lisp/elpa-src/flycheck-32snapshot/flycheck-pkg
/usr/share/emacs/site-lisp/elpa/flycheck-32snapshot/flycheck-ert hides
/usr/share/emacs/site-lisp/elpa-src/flycheck-32snapshot/flycheck-ert
/usr/share/emacs/site-lisp/elpa/flycheck-32snapshot/flycheck hides
/usr/share/emacs/site-lisp/elpa-src/flycheck-32snapshot/flycheck
/usr/share/emacs/site-lisp/elpa/flycheck-32snapshot/flycheck-buttercup
hides
/usr/share/emacs/site-lisp/elpa-src/flycheck-32snapshot/flycheck-buttercup
/usr/share/emacs/site-lisp/elpa/js2-mode-20180301/js2-mode-pkg hides
/usr/share/emacs/site-lisp/elpa-src/js2-mode-20180301/js2-mode-pkg
/usr/share/emacs/site-lisp/elpa/js2-mode-20180301/js2-mode-autoloads hides
/usr/share/emacs/site-lisp/elpa-src/js2-mode-20180301/js2-mode-autoloads
/usr/share/emacs/site-lisp/elpa/js2-mode-20180301/js2-imenu-extras hides
/usr/share/emacs/site-lisp/elpa-src/js2-mode-20180301/js2-imenu-extras
/usr/share/emacs/site-lisp/elpa/js2-mode-20180301/js2-old-indent hides
/usr/share/emacs/site-lisp/elpa-src/js2-mode-20180301/js2-old-indent
/usr/share/emacs/site-lisp/elpa/js2-mode-20180301/js2-mode hides
/usr/share/emacs/site-lisp/elpa-src/js2-mode-20180301/js2-mode
/usr/share/emacs/site-lisp/elpa/let-alist-1.0.6/let-alist hides
/usr/share/emacs/site-lisp/elpa-src/let-alist-1.0.6/let-alist
/usr/share/emacs/site-lisp/elpa/let-alist-1.0.6/let-alist-pkg hides
/usr/share/emacs/site-lisp/elpa-src/let-alist-1.0.6/let-alist-pkg
/usr/share/emacs/site-lisp/elpa/let-alist-1.0.6/let-alist-autoloads hides
/usr/share/emacs/site-lisp/elpa-src/let-alist-1.0.6/let-alist-autoloads
~/.emacs.d/site-lisp/markdown-mode hides
/usr/share/emacs/site-lisp/elpa-src/markdown-mode-2.4/markdown-mode
/usr/share/emacs/site-lisp/elpa/markdown-mode-2.4/markdown-mode-pkg hides
/usr/share/emacs/site-lisp/elpa-src/markdown-mode-2.4/markdown-mode-pkg
/usr/share/emacs/site-lisp/elpa/markdown-mode-2.4/markdown-mode-autoloads
hides
/usr/share/emacs/site-lisp/elpa-src/markdown-mode-2.4/markdown-mode-autoloads
/usr/share/emacs/site-lisp/elpa/pkg-info-0.6/pkg-info-autoloads hides
/usr/share/emacs/site-lisp/elpa-src/pkg-info-0.6/pkg-info-autoloads
/usr/share/emacs/site-lisp/elpa/pkg-info-0.6/pkg-info-pkg hides
/usr/share/emacs/site-lisp/elpa-src/pkg-info-0.6/pkg-info-pkg
/usr/share/emacs/site-lisp/elpa/pkg-info-0.6/pkg-info hides
/usr/share/emacs/site-lisp/elpa-src/pkg-info-0.6/pkg-info
/usr/share/emacs/site-lisp/elpa/seq-2.22/seq-25 hides
/usr/share/emacs/site-lisp/elpa-src/seq-2.22/seq-25
/usr/share/emacs/site-lisp/elpa/seq-2.22/seq-pkg hides
/usr/share/emacs/site-lisp/elpa-src/seq-2.22/seq-pkg
/usr/share/emacs/site-lisp/elpa/seq-2.22/seq-24 hides
/usr/share/emacs/site-lisp/elpa-src/seq-2.22/seq-24
/usr/share/emacs/site-lisp/elpa/seq-2.22/seq hides
/usr/share/emacs/site-lisp/elpa-src/seq-2.22/seq
/usr/share/emacs/site-lisp/elpa/seq-2.22/seq-autoloads hides
/usr/share/emacs/site-lisp/elpa-src/seq-2.22/seq-autoloads
/usr/share/emacs/site-lisp/elpa/solarized-theme-1.3.1/solarized hides
/usr/share/emacs/site-lisp/elpa-src/solarized-theme-1.3.1/solarized
/usr/share/emacs/site-lisp/elpa/solarized-theme-1.3.1/solarized-theme-pkg
hides
/usr/share/emacs/site-lisp/elpa-src/solarized-theme-1.3.1/solarized-theme-pkg
/usr/share/emacs/site-lisp/elpa/solarized-theme-1.3.1/solarized-light-theme
hides
/usr/share/emacs/site-lisp/elpa-src/solarized-theme-1.3.1/solarized-light-theme
/usr/share/emacs/site-lisp/elpa/solarized-theme-1.3.1/solarized-dark-theme
hides
/usr/share/emacs/site-lisp/elpa-src/solarized-theme-1.3.1/solarized-dark-theme
/usr/share/emacs/site-lisp/elpa/solarized-theme-1.3.1/solarized-theme-utils
hides
/usr/share/emacs/site-lisp/elpa-src/solarized-theme-1.3.1/solarized-theme-utils
/usr/share/emacs/site-lisp/elpa/solarized-theme-1.3.1/solarized-theme-autoloads
hides
/usr/share/emacs/site-lisp/elpa-src/solarized-theme-1.3.1/solarized-theme-autoloads
/usr/share/emacs/site-lisp/elpa/solarized-theme-1.3.1/solarized-theme
hides
/usr/share/emacs/site-lisp/elpa-src/solarized-theme-1.3.1/solarized-theme
/usr/share/emacs/site-lisp/elpa/ws-butler-0.6/ws-butler-autoloads hides
/usr/share/emacs/site-lisp/elpa-src/ws-butler-0.6/ws-butler-autoloads
/usr/share/emacs/site-lisp/elpa/ws-butler-0.6/ws-butler hides
/usr/share/emacs/site-lisp/elpa-src/ws-butler-0.6/ws-butler
/usr/share/emacs/site-lisp/elpa/ws-butler-0.6/ws-butler-pkg hides
/usr/share/emacs/site-lisp/elpa-src/ws-butler-0.6/ws-butler-pkg
/usr/share/emacs/site-lisp/elpa/yaml-mode-0.0.14/yaml-mode-pkg hides
/usr/share/emacs/site-lisp/elpa-src/yaml-mode-0.0.14/yaml-mode-pkg
/usr/share/emacs/site-lisp/elpa/yaml-mode-0.0.14/yaml-mode hides
/usr/share/emacs/site-lisp/elpa-src/yaml-mode-0.0.14/yaml-mode
/usr/share/emacs/site-lisp/elpa/yaml-mode-0.0.14/yaml-mode-autoloads hides
/usr/share/emacs/site-lisp/elpa-src/yaml-mode-0.0.14/yaml-mode-autoloads
/usr/share/emacs/site-lisp/elpa/zenburn-theme-2.6/zenburn-theme-autoloads
hides
/usr/share/emacs/site-lisp/elpa-src/zenburn-theme-2.6/zenburn-theme-autoloads
/usr/share/emacs/site-lisp/elpa/zenburn-theme-2.6/zenburn-theme hides
/usr/share/emacs/site-lisp/elpa-src/zenburn-theme-2.6/zenburn-theme
/usr/share/emacs/site-lisp/elpa/zenburn-theme-2.6/zenburn-theme-pkg hides
/usr/share/emacs/site-lisp/elpa-src/zenburn-theme-2.6/zenburn-theme-pkg
/usr/share/emacs/site-lisp/elpa/seq-2.22/seq hides
/usr/share/emacs/27.1/lisp/emacs-lisp/seq
/usr/share/emacs/site-lisp/elpa/let-alist-1.0.6/let-alist hides
/usr/share/emacs/27.1/lisp/emacs-lisp/let-alist

Features:
(shadow sort mail-extr emacsbug sendmail find-dired ffap grep
network-stream nsm gnus-agent gnus-srvr gnus-score score-mode nnvirtual
gnus-msg gnus-art mm-uu mml2015 mm-view mml-smime smime dig nntp
gnus-cache gnus-sum shr svg xml dom gnus-group gnus-undo gnus-start
gnus-cloud nnimap nnmail mail-source utf7 netrc nnoo gnus-spec gnus-int
gnus-range message rmc puny dired dired-loaddefs rfc822 mml mml-sec epa
epg epg-config mm-decode mm-bodies mm-encode mail-parse rfc2231
mailabbrev gmm-utils mailheader gnus-win gnus nnheader gnus-util rmail
rmail-loaddefs rfc2047 rfc2045 ietf-drums text-property-search
mail-utils mm-util mail-prsvr wid-edit pylint compile python tramp-sh
tramp tramp-loaddefs trampver tramp-integration files-x tramp-compat
shell pcomplete parse-time iso8601 ls-lisp format-spec misearch
multi-isearch thingatpt time-date pcase vc-git diff-mode disp-table
fill-column-indicator modern-cpp-font-lock flycheck find-func help-mode
dash whitespace coffee-mode easy-mmode comint ansi-color php-mode
cc-langs speedbar sb-image ezimage dframe ws-trim stylus-mode sws-mode
pug-mode jade-mode nsis-mode hideshow saveplace autorevert filenotify
cus-start cus-load json-mode edmacro kmacro derived json-reformat cl
json-snatcher rx js2-mode etags fileloop generator xref project ring js
cc-mode cc-fonts cc-guess cc-menus cc-cmds cc-styles cc-align cc-engine
cc-vars cc-defs imenu finder-inf tempo url url-proxy url-privacy
url-expand url-methods url-history url-cookie url-domsuf url-util
mailcap xml-parse doxymacs devhelp package easymenu browse-url
url-handlers url-parse auth-source cl-seq eieio eieio-core cl-macs
eieio-loaddefs password-cache json subr-x map url-vars seq seq-25
byte-opt gv bytecomp byte-compile cconv cl-loaddefs cl-lib tooltip eldoc
electric uniquify ediff-hook vc-hooks lisp-float-type mwheel term/x-win
x-win term/common-win x-dnd tool-bar dnd fontset image regexp-opt fringe
tabulated-list replace newcomment text-mode elisp-mode lisp-mode
prog-mode register page tab-bar menu-bar rfn-eshadow isearch timer
select scroll-bar mouse jit-lock font-lock syntax facemenu font-core
term/tty-colors frame minibuffer cl-generic cham georgian utf-8-lang
misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms
cp51932 hebrew greek romanian slovak czech european ethiopic indian
cyrillic chinese composite charscript charprop case-table epa-hook
jka-cmpr-hook help simple abbrev obarray cl-preloaded nadvice loaddefs
button faces cus-face macroexp files text-properties overlay sha1 md5
base64 format env code-pages mule custom widget hashtable-print-readable
backquote threads dbusbind inotify lcms2 dynamic-setting
system-font-setting font-render-setting cairo move-toolbar gtk x-toolkit
x multi-tty make-network-process emacs)

Memory information:
((conses 16 341729 22207)
 (symbols 48 29654 3)
 (strings 32 88700 3401)
 (string-bytes 1 3119566)
 (vectors 16 47059)
 (vector-slots 8 596070 47936)
 (floats 8 259 37)
 (intervals 56 7741 122)
 (buffers 1000 27))

-- 
Cauldron Development LLC
http://www.cauldrondevelopment.com/
Cell: 208-409-9128