summaryrefslogtreecommitdiff
path: root/amiga
diff options
context:
space:
mode:
Diffstat (limited to 'amiga')
-rw-r--r--amiga/font.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/amiga/font.c b/amiga/font.c
index f4ef87822..458e1d06c 100644
--- a/amiga/font.c
+++ b/amiga/font.c
@@ -240,7 +240,6 @@ bool nsfont_split(const plot_font_style_t *fstyle,
int x, size_t *char_offset, int *actual_x)
{
ULONG co;
- const char *str_pos = string;
uint16 *utf16 = NULL,*outf16 = NULL;
uint16 utf16next = 0;
FIXED kern = 0;
@@ -295,7 +294,7 @@ bool nsfont_split(const plot_font_style_t *fstyle,
/* Reached available width, and a space has been found; split there. */
break;
- } else if (*(string + str_pos) == ' ') {
+ } else if (*(string + utf8_pos) == ' ') {
*actual_x = tx;
coffset = utf8_pos;