[chronojump] Fixed crash on importing session (from encoder) where no jump types defined (really rare)



commit a6259b4ff7eaaf0f3203769837acb7accef479dd
Author: Xavier de Blas <xaviblas gmail com>
Date:   Mon Oct 18 10:11:38 2021 +0200

    Fixed crash on importing session (from encoder) where no jump types defined (really rare)

 src/gui/app1/jump.cs | 3 +++
 1 file changed, 3 insertions(+)
---
diff --git a/src/gui/app1/jump.cs b/src/gui/app1/jump.cs
index 9888a4ade..e2de140c3 100644
--- a/src/gui/app1/jump.cs
+++ b/src/gui/app1/jump.cs
@@ -180,6 +180,9 @@ public partial class ChronoJumpWindow
        private void on_extra_window_jumps_test_changed(object o, EventArgs args)
        {
                string jumpEnglishName = comboSelectJumps.GetSelectedNameEnglish();
+               if(jumpEnglishName == "") //if there are no jump types
+                       return;
+
                currentJumpType = createJumpType(jumpEnglishName, true);
 
                //change name of this radio but only if changed (to not have it flickering on hpaned1 
displacement)


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]