unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Stephen Berman <stephen.berman@gmx.net>
To: Michael Heerdegen <michael_heerdegen@web.de>
Cc: 25522@debbugs.gnu.org
Subject: bug#25522: 26.0.50; (hl-line-maybe-unhighlight): (error "Selecting deleted buffer")
Date: Thu, 26 Jan 2017 20:45:11 +0100	[thread overview]
Message-ID: <87mvedip14.fsf@gmx.net> (raw)
In-Reply-To: <8737g8jaz4.fsf@web.de>

On Thu, 26 Jan 2017 11:15:24 +0100 Michael Heerdegen <michael_heerdegen@web.de> wrote:

> Stephen Berman <stephen.berman@gmx.net> writes:
>
>> > I just got the same error message after hitting U x in M-x
>> > list-packages.
>>
>> Is this after removing the above sexp?
>
> No, still with hl-line-sticky-flag -> nil.
>
>
>> Did you have hl-line-mode enabled in package-menu-mode, and if so,
>> how?  I added this:
>>
>> (add-hook 'package-menu-mode-hook #'hl-line-mode)
>
> Yes, that's exactly what I use - sorry for my terseness.
>
>
>> -    (when (and (not hl-line-sticky-flag)
>> +    (when (and (buffer-live-p hlob)
>> +               (not hl-line-sticky-flag)
>
> Yeah, that seems to fix the problem (I had already tried that ;-)).  I
> still wonder why you don't see it...but I'm not sure if it's worth to
> investigate (because this will probably take hours).

I think I found out what triggers the error: when you kill a buffer in
whose mode hl-line-mode is enabled and the mode of the next (now
current) buffer does not have hl-line-mode enabled, and then you change
(or Emacs changes) to another buffer in whose mode hl-line-mode is
enabled -- that raises the error.  Can you confirm this?  Just out of
curiosity, because I think the above fix is good enough and it's simple,
so unless someone sees a problem with it, I'll commit it to master.

Steve Berman





  reply	other threads:[~2017-01-26 19:45 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-24 23:26 bug#25522: 26.0.50; (hl-line-maybe-unhighlight): (error "Selecting deleted buffer") Michael Heerdegen
2017-01-24 23:39 ` Michael Heerdegen
2017-01-25 12:16   ` Stephen Berman
2017-01-26  1:14     ` Michael Heerdegen
2017-01-26  1:21       ` Michael Heerdegen
2017-01-26  2:07         ` Michael Heerdegen
2017-01-26  9:54           ` Stephen Berman
2017-01-26 10:15             ` Michael Heerdegen
2017-01-26 19:45               ` Stephen Berman [this message]
2017-01-27  9:29                 ` Michael Heerdegen
2017-01-28 19:52                   ` Stephen Berman

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87mvedip14.fsf@gmx.net \
    --to=stephen.berman@gmx.net \
    --cc=25522@debbugs.gnu.org \
    --cc=michael_heerdegen@web.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).