Skip to content

Commit

Permalink
Fix operator precedence
Browse files Browse the repository at this point in the history
  • Loading branch information
mjunix authored and hpjansson committed Aug 13, 2023
1 parent c389ef0 commit e5b48dd
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions chafa/chafa-util.c
Expand Up @@ -95,13 +95,13 @@ chafa_calc_canvas_geometry (gint src_width,
{
if (dest_width_inout)
{
*dest_width_inout = (src_width + 7 / 8);
*dest_width_inout = (src_width + 7) / 8;
*dest_width_inout = MAX (*dest_width_inout, 1);
}

if (dest_height_inout)
{
*dest_height_inout = (src_height + 7 / 8) * font_ratio + 0.5;
*dest_height_inout = ((src_height + 7) / 8) * font_ratio + 0.5;
*dest_height_inout = MAX (*dest_height_inout, 1);
}

Expand Down

0 comments on commit e5b48dd

Please sign in to comment.