From e1bca7c98571e8888f4d49543b42218c24b7a2ae Mon Sep 17 00:00:00 2001 From: Felix Domke Date: Sun, 18 Jun 2006 21:10:11 +0000 Subject: [PATCH] fix empty strings --- lib/gdi/font.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/gdi/font.cpp b/lib/gdi/font.cpp index f7c1bca5..77c8de94 100644 --- a/lib/gdi/font.cpp +++ b/lib/gdi/font.cpp @@ -470,9 +470,9 @@ int eTextPara::renderString(const char *string, int rflags) if (string) uc_string.reserve(strlen(string)); - const char *p = string; + const char *p = string ? string : ""; - while(p) + while (*p) { unsigned int unicode=(unsigned char)*p++; -- 2.30.2