diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/list_window.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/list_window.c b/src/list_window.c index b541ac708..c6f5375a1 100644 --- a/src/list_window.c +++ b/src/list_window.c @@ -245,6 +245,8 @@ list_window_find(list_window_t *lw, } if( wrap ) { + if ( i==0 ) /* empty list */ + return 1; i=0; /* first item */ screen_bell(); } @@ -265,6 +267,9 @@ list_window_rfind(list_window_t *lw, int i = lw->selected-1; char *label; + if ( rows == 0 ) + return 1; + while( wrap || i==lw->selected-1 ) { while( i>=0 && (label=(callback) (i,&h,callback_data)) ) |