From 8233f31269e15cfec2f736130edb3ee0392834dc Mon Sep 17 00:00:00 2001 From: veclavtalica Date: Wed, 15 Jan 2025 06:50:19 +0300 Subject: [PATCH] oopsie --- src/twn_loop.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/twn_loop.c b/src/twn_loop.c index 43e94ce..c562d37 100644 --- a/src/twn_loop.c +++ b/src/twn_loop.c @@ -613,9 +613,9 @@ static bool initialize(void) { if (!datum_font_filtering.ok) { ctx.font_filtering = TEXT_FONT_FILTERING_DEFAULT; } else { - if (SDL_strncmp(datum_font_filtering.u.s, "nearest", sizeof "nearest") == 0) { + if (SDL_strncmp(datum_font_filtering.u.s, "nearest", sizeof "nearest" - 1) == 0) { ctx.font_filtering = TEXTURE_FILTER_NEAREAST; - } else if (SDL_strncmp(datum_font_filtering.u.s, "linear", sizeof "nearest") == 0) { + } else if (SDL_strncmp(datum_font_filtering.u.s, "linear", sizeof "linear" - 1) == 0) { ctx.font_filtering = TEXTURE_FILTER_LINEAR; } else { ctx.font_filtering = TEXT_FONT_FILTERING_DEFAULT;