Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: [PATCH] Re: Bug: Callback to widget set with `zle -Fw <widget>` shouldn't change $LASTWIDGET



On Sun, Jul 16, 2023 at 3:29 AM dana <dana@xxxxxxx> wrote:
>
> On Tue 17 Jan 2023, at 12:00, Bart Schaefer wrote:
> > My concern is that the Thingy pointer becomes invalid
>
> I think this was justified
>
> I've just tried running a new HEAD build for the first time in several months
> and found that back-spacing causes the shell to crash.

The patch from the start of this thread has never been committed, so
is not directly related.  That is, if the Thingy is invalid, it's not
$LASTWIDGET that's making the bad reference here, so fixing
save/restore there probably will not resolve the problem.

In your backtrace I see
  _zsh_autosuggest_widget_modify
and
  _zsh_autosuggest_invoke_original_widget
followed by
  _zsh_highlight_widget_orig-s0.0000030000-r21548-backward-delete-char
and finally
  _zsh_highlight_call_widget
causes the actual crash below unrefthingy(), so I suspect this is a
reference-counting problem.




Messages sorted by: Reverse Date, Date, Thread, Author