X-Git-Url: https://git.ucc.asn.au/?a=blobdiff_plain;f=Usermode%2FApplications%2Faxwin3_src%2FWM%2Fwm_render_text.c;h=8258531bcc71c5097fd56986c66c0dc680815e9d;hb=97088ef688ddecc19077ce134046af7ea6d1e232;hp=d189e5e04b98e19de8a799e84a1b07b2cc2ce56a;hpb=f0c407e7d468bc5acfd8d436be7f79f6e6248421;p=tpg%2Facess2.git diff --git a/Usermode/Applications/axwin3_src/WM/wm_render_text.c b/Usermode/Applications/axwin3_src/WM/wm_render_text.c index d189e5e0..8258531b 100644 --- a/Usermode/Applications/axwin3_src/WM/wm_render_text.c +++ b/Usermode/Applications/axwin3_src/WM/wm_render_text.c @@ -8,7 +8,8 @@ #include #include #include -#include +#include +#include // INT_MAX // === TYPES === typedef struct sGlyph tGlyph; @@ -171,7 +172,7 @@ tGlyph *_GetGlyph(tFont *Font, uint32_t Codepoint) prev = next, next = next->Next ); - if( next->Codepoint == Codepoint ) + if( next && next->Codepoint == Codepoint ) return next; } @@ -185,7 +186,7 @@ tGlyph *_GetGlyph(tFont *Font, uint32_t Codepoint) prev && prev->Codepoint > Codepoint; next = prev, prev = prev->Prev ); - if( prev->Codepoint == Codepoint ) + if( prev && prev->Codepoint == Codepoint ) return prev; } }