Skip to content

fix(k2proc): dead code in get_line_spacing_pixels() - #65

Open
tachibana-shin wants to merge 1 commit into
koreader:masterfrom
tachibana-shin:fix/dead-code-k2proc
Open

fix(k2proc): dead code in get_line_spacing_pixels()#65
tachibana-shin wants to merge 1 commit into
koreader:masterfrom
tachibana-shin:fix/dead-code-k2proc

Conversation

@tachibana-shin

@tachibana-shin tachibana-shin commented Jul 22, 2026

Copy link
Copy Markdown
if (allow_text_wrapping)
    if (mlp->median_line_spacing > 0.)
        row_line_spacing_pixels = mlp->median_line_spacing;
    else
        row_line_spacing_pixels = 1.2 * median_single_space_pixels;

when median_line_spacing is zero or negative, the code correctly falls back to 1.2 * median_single_space_pixels instead of silently using an uninitialized/stale value.


This change is Reviewable

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants