From 24b7fdf4382dcef274092b4735093fc390815455 Mon Sep 17 00:00:00 2001 From: Michael Drake Date: Mon, 2 Jan 2017 11:59:32 +0000 Subject: Framebuffer: Fix freetype font table to return nserror. We were returning true on success, which when the return value was tested for being NSERROR_OK (0), meant it was treated as failure. Now we correctly return NSERROR_OK on success. --- frontends/framebuffer/font_freetype.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'frontends/framebuffer') diff --git a/frontends/framebuffer/font_freetype.c b/frontends/framebuffer/font_freetype.c index 9235ad476..323982014 100644 --- a/frontends/framebuffer/font_freetype.c +++ b/frontends/framebuffer/font_freetype.c @@ -444,8 +444,7 @@ fb_font_width(const plot_font_style_t *fstyle, *width += glyph->advance.x >> 16; } - - return true; + return NSERROR_OK; } @@ -481,7 +480,7 @@ fb_font_position(const plot_font_style_t *fstyle, *actual_x = prev_x; *char_offset = nxtchr; - return true; + return NSERROR_OK; } @@ -537,7 +536,7 @@ fb_font_split(const plot_font_style_t *fstyle, * found a space; return previous space */ *actual_x = last_space_x; *char_offset = last_space_idx; - return true; + return NSERROR_OK; } nxtchr = utf8_next(string, length, nxtchr); @@ -545,7 +544,7 @@ fb_font_split(const plot_font_style_t *fstyle, *char_offset = nxtchr; - return true; + return NSERROR_OK; } static struct gui_layout_table layout_table = { -- cgit v1.2.3