diff --git a/window.c b/window.c index 3219c2d..20ca1fc 100644 --- a/window.c +++ b/window.c @@ -42,7 +42,9 @@ void window_top(WINDOW *win){ mvwaddstr(win, 0, 0, top_buffer); mvwaddch(win, 0, strlen(top_buffer), '/'); wattroff(win, COLOR_PAIR(COLOR_PATH)); - mvwaddstr(win, 0, strlen(top_buffer)+1, mid_content[selected_file_current].file_name); + if (mid_file_count != 0) { + mvwaddstr(win, 0, strlen(top_buffer)+1, mid_content[selected_file_current].file_name); + } } pthread_mutex_unlock(&mutex_top); } else {