diff options
author | Ian Moffett <ian@osmora.org> | 2025-08-04 23:52:01 -0400 |
---|---|---|
committer | Ian Moffett <ian@osmora.org> | 2025-08-04 23:52:01 -0400 |
commit | 1da5b911bc3280239d4be4d3c6002c8c7a40c74e (patch) | |
tree | 9379d227149e899a1d1a2920bc072c5f61ad2eb5 | |
parent | 3472fff80fdec0aa40e7a364bb878cc6fd9eaeb7 (diff) |
lib: libgfx: Fix one line bugs
- Add missing return statement
- Fix x/y mismatch
Signed-off-by: Ian Moffett <ian@osmora.org>
-rw-r--r-- | lib/libgfx/src/draw.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/libgfx/src/draw.c b/lib/libgfx/src/draw.c index 43e0f08..a0061b9 100644 --- a/lib/libgfx/src/draw.c +++ b/lib/libgfx/src/draw.c @@ -58,7 +58,7 @@ gfx_pixel_bounds(struct gfx_ctx *ctx, uint32_t x, uint32_t y) scr_width = fbdev.width; scr_height = fbdev.height; - if (x >= scr_height || y >= scr_width) { + if (x >= scr_width || y >= scr_height) { return -1; } @@ -221,4 +221,6 @@ gfx_copy_region(struct gfx_ctx *ctx, struct gfx_region *r, scrpos_t x, scrpos_t gfx_plot_point(ctx, &point); } } + + return 0; } |