Subject: Re: bug#57804: An infinite loop in a `fontify-region' function causes Emacs to hang indefinitely

From: Gregory Heytings <[email-masked]>
Date: Thu, 15 Sep 2022 19:44:30 +0000

>> already told you thrice that a simple way to fix your problem is to set 
>> long-line-threshold to a larger value (or to nil).
> 
> Thanks, I added  `(setf long-line-threshold nil)' to Emacs startup 
> configuration file a couple of days before. But unless I'm missing 
> something, this is not a fix, only a workaround.
>

Why did you immediately set it to nil instead of trying to making it 
sufficiently large?  You said that some lines in the Logview buffer are 
long, but I bet they are never longer than, say, 100000 characters.

As I told you, the general fix will be to adapt Logview to handle locked 
narrowing, by explicitly unlocking the locked narrowing when it needs to 
access a larger portion of the buffer.  You were somewhat reluctant at 
that idea.