Skip to content

toggle_dotfile cause memory corruption #55

Description

@kalocsaibotond

I played around with Sfm-s toggle dotfile and I found a case where memory corruption occur.
I tested it on Void Linux.
Steps to reproduce:

  1. Open Sfm in the home directory
  2. Press G to jump to the last entry.
  3. Press . to toggle dotfiles

Result:
Image
(The homedir has way more dotfiles then not dotfiles)

I believe it is related to another segmentation fault error. Sometimes when I select large number of entries (100 - 200) with move_cursor in visual mode, then use cd_to_parent, I get segmentation fault.:
Image

In addition, when I tried to write a patch for cd_to_parent to put the cursor on the parent, and center the view to it, when current_pane->start_index was anything other than zero, I got memory corruption for smaller non-zero values and I got segmentation fault at larger values (~50 or above).

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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