From 45aeb9ad89c6115e6cd66df36b280a5b4e58d080 Mon Sep 17 00:00:00 2001 From: Jonathan Moore Liles Date: Tue, 6 May 2008 15:35:08 -0500 Subject: [PATCH] Fix menu settings loader when operating at close to depth 0. --- Timeline/Fl_Menu_Settings.C | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/Timeline/Fl_Menu_Settings.C b/Timeline/Fl_Menu_Settings.C index ca922a5..2caa3a3 100644 --- a/Timeline/Fl_Menu_Settings.C +++ b/Timeline/Fl_Menu_Settings.C @@ -234,9 +234,10 @@ path_pop ( char *path ) s = rindex( path, '/' ); - s = s ? s : path; - - *(s + 1) = '\0'; + if ( s ) + *(s + 1) = '\0'; + else + *path = '\0'; } void