Skip to content

Freezes with 100% CPU in one core #1310

@Disonantemus

Description

@Disonantemus

Problem

I have a bug vis-smart-numbers plugin, if it's enabled, when in command mode, I press Escape or Ctrl-c, vis freezes, and one CPU core stays 100% until I kill it with pkill -9 vis:

Plugin list in the wiki: https://github.com/martanne/vis/wiki/Plugins

I did look at the Lua code of the plugin, I'm no programmer, but it was very simple and I didn't catch any problem.

visrc.lua

Minimal visrc.lua, default file config and vis-smart-numbers plugin:

-- load standard vis module, providing parts of the Lua API
require('vis')
require("plugins/vis-smart-numbers")
vis.events.subscribe(vis.events.INIT, function()
        -- Your global configuration options
end)
vis.events.subscribe(vis.events.WIN_OPEN, function(win) -- luacheck: no unused args
        -- Your per window configuration options e.g.
        -- vis:command('set number')
end)

System

distro: Arch Linux x86_64
kernel: 6.12.33-1-lts
shell: bash 5.3.9
term: tmux 3.6a

Steps to reproduce

Compile last git and run vis:

git clone https://github.com/martanne/vis
cd vis/
./configure
make
sudo make install
vis -v
vis v0.9-372-gc71a6c5 +curses +lua +tre +acl
foot -v
foot version: 1.25.0 +pgo +ime +graphemes -assertions
echo $TERM
screen-256color
vis

When vis is launched:

  1. press : to enter command mode
  2. press Escape or Ctrl-c

vis version (vis -v)

vis v0.9-372-gc71a6c5 +curses +lua +tre +acl

Terminal name/version

foot version: 1.25.0 +pgo +ime +graphemes -assertions

TERM environment variable

screen-256color

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions