focus-editor / focus

A simple and fast text editor
GNU General Public License v3.0
1.82k stars 99 forks source link

Crash when opening workspace text search after reloading workspace #322

Closed ostef closed 8 months ago

ostef commented 8 months ago

Focus version: 0.3.2 release, OS: Windows 10

The editor crashed when I opened the workspace text search panel.

This happened after I reloaded my workspace so maybe it's part of the issue. Looking at the source code it seems it's trying to access a buffer that does not exist anymore.

This is the crash report: Assertion failed in file W:/focus/modules/Simple_Bucket_Array.jai at line 79, char 5: Simple_Bucket_Array index outside of range

Stack trace: W:/focus/modules/Runtime_Support.jai:692: report_error_in_yer_face W:/focus/modules/Runtime_Support.jai:667: report_failed_assertion_more_visibly W:/focus/modules/Runtime_Support.jai:123: runtime_support_assertion_failed C:/jai/modules/Basic/module.jai:87: assert_helper W:/focus/modules/Simple_Bucket_Array.jai:79: *[] W:/focus/src/draw.jai:2623: draw_finder W:/focus/src/draw.jai:69: draw_frame W:/focus/src/main.jai:272: main

focus-editor commented 8 months ago

Please try the latest nightly, it's been fixed there for some time now.

On Wed, Mar 20, 2024, 11:07 PM Stefan @.***> wrote:

Focus version: 0.3.2 release, OS: Windows 10

The editor crashed when I opened the workspace text search panel.

This happened after I reloaded my workspace so maybe it's part of the issue. Looking at the source code it seems it's trying to access a buffer that does not exist anymore.

This is the crash report: Assertion failed in file W:/focus/modules/Simple_Bucket_Array.jai at line 79, char 5: Simple_Bucket_Array index outside of range

Stack trace: W:/focus/modules/Runtime_Support.jai:692: report_error_in_yer_face W:/focus/modules/Runtime_Support.jai:667: report_failed_assertion_more_visibly W:/focus/modules/Runtime_Support.jai:123: runtime_support_assertion_failed C:/jai/modules/Basic/module.jai:87: assert_helper W:/focus/modules/Simple_Bucket_Array.jai:79: *[] W:/focus/src/draw.jai:2623: draw_finder W:/focus/src/draw.jai:69: draw_frame W:/focus/src/main.jai:272: main

— Reply to this email directly, view it on GitHub https://github.com/focus-editor/focus/issues/322, or unsubscribe https://github.com/notifications/unsubscribe-auth/A4OX77VVIWK3UWTEX4F22UDYZFNVVAVCNFSM6AAAAABE7E4KB6VHI2DSMVQWIX3LMV43ASLTON2WKOZSGE4TOMJUGAZDQNA . You are receiving this because you are subscribed to this thread.Message ID: @.***>

ostef commented 8 months ago

Okay, my bad! I'll make sure to try reproducing bugs using the latest version in the future