From 8edfc767a3d6bd3e8c53a32fb9e26014f425b132 Mon Sep 17 00:00:00 2001 From: Simon Tatham Date: Mon, 25 Feb 2019 20:30:38 +0000 Subject: [PATCH] minibidi.c: include putty.h and fix clashes. The bidi_char structure was declared twice, with nothing to keep them in sync; also, is_rtl had a mismatch of return types. --- minibidi.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/minibidi.c b/minibidi.c index 97f4d13f..41830636 100644 --- a/minibidi.c +++ b/minibidi.c @@ -23,6 +23,7 @@ #include /* definition of wchar_t*/ +#include "putty.h" #include "misc.h" #define LMASK 0x3F /* Embedding Level mask */ @@ -49,11 +50,6 @@ shapetypes[(xh)-SHAPE_FIRST].type : SU) /*))*/ #define leastGreaterOdd(x) ( ((x)+1) | 1 ) #define leastGreaterEven(x) ( ((x)+2) &~ 1 ) -typedef struct bidi_char { - unsigned int origwc, wc; - unsigned short index; -} bidi_char; - /* function declarations */ static void flipThisRun( bidi_char *from, unsigned char *level, int max, int count); @@ -1027,7 +1023,7 @@ static unsigned char getType(int ch) * important because all such characters are right-to-left so it * would have flagged them anyway.) */ -int is_rtl(int c) +bool is_rtl(int c) { /* * After careful reading of the Unicode bidi algorithm (URL as