summaryrefslogtreecommitdiff
path: root/src/til_fb.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/til_fb.c')
-rw-r--r--src/til_fb.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/til_fb.c b/src/til_fb.c
index cc07909..0f7fe83 100644
--- a/src/til_fb.c
+++ b/src/til_fb.c
@@ -174,12 +174,12 @@ static _til_fb_page_t * _til_fb_page_apply_ratio(_til_fb_page_t *page)
ratio = page->fb->ratio;
fragment = &page->fragment.public;
- assert(fragment->frame_width > 0 && fragment->frame_height > 0);
- assert(ratio > 0.f);
-
if (isnan(ratio))
return page;
+ assert(fragment->frame_width > 0 && fragment->frame_height > 0);
+ assert(ratio > 0.f);
+
fragment_ratio = (float)fragment->frame_width / (float)fragment->frame_height;
d = fragment_ratio - ratio;
if (d < 0) { /* letterboxed, scale height */
© All Rights Reserved