intvsteve / VINTage

Various Intellivision-related projects, including the LTO Flash! User Interface application.
GNU General Public License v2.0
3 stars 1 forks source link

UI hard crashes when adding file in certain circumstances #343

Open intvsteve opened 4 years ago

intvsteve commented 4 years ago

When dragging a ROM from the ROM list to the menu layout, the UI crashes with a NullReferenceException.

Operating system version

Windows (all versions)

Program version (from About box)

All versions

Expected behavior

It doesn't crash. :P Two expected outcomes:

Actual behavior

Crash! (NullReferenceException)

Steps to reproduce

  1. Fill up the root of the Menu Layout with 255 items -- at least one must be a folder!
  2. Drag a ROM from the ROMs list to a folder that does not have 255 items in it

Crash log if available (paste or attach)

ErrorLog_2020-08-09-11-26-51-769.txt

intvsteve commented 4 years ago

The bug is triggered in the Windows drag/drop code in FileNodeViewModel.WPF.cs in which it fails to correctly get the menu layout object to save changes to.

intvsteve commented 4 years ago

WORKAROUND

  1. In the root folder, remove a ROM
  2. Now things should work

It's possible this bug is not specific to the root folder being full - need to verify if it also happens with a folder that has 255 items, one of which is a folder, and the same kind of action is attempted.