diff options
-rw-r--r-- | apps/gui/scrollbar.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/apps/gui/scrollbar.c b/apps/gui/scrollbar.c index 8a0b885c4b..0f2a485b32 100644 --- a/apps/gui/scrollbar.c +++ b/apps/gui/scrollbar.c | |||
@@ -96,10 +96,8 @@ void gui_scrollbar_draw(struct screen * screen, int x, int y, | |||
96 | /* Boundary check to make sure that height is reasonable, otherwise nothing | 96 | /* Boundary check to make sure that height is reasonable, otherwise nothing |
97 | * to do | 97 | * to do |
98 | */ | 98 | */ |
99 | if(height<2 || width<2) | 99 | if ((inner_wd | inner_ht) < 0) |
100 | { | ||
101 | return; | 100 | return; |
102 | } | ||
103 | 101 | ||
104 | if (flags & HORIZONTAL) | 102 | if (flags & HORIZONTAL) |
105 | inner_len = inner_wd; | 103 | inner_len = inner_wd; |