From e891e6fa98eeff0740e1d4e4134ff79d57fdd4af Mon Sep 17 00:00:00 2001 From: tagoh Date: Thu, 25 May 2006 07:41:09 +0000 Subject: * src/paps.c (split_text_into_paragraphs): fixed a possible segfault issue. --- ChangeLog | 5 ++++- src/paps.c | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index 66024d4..82b2586 100644 --- a/ChangeLog +++ b/ChangeLog @@ -2,9 +2,12 @@ * src/paps.1: fixed a typo. (#1491827) - * src/paps.c: changed an option name --font_scale to --font-scale + * src/paps.c (main): changed an option name --font_scale to --font-scale according to other options prefers a hyphen other than underscore. + * src/paps.c (split_text_into_paragraphs): fixed a possible segfault + issue. + 2006-04-26 Dov Grobgeld * src/libpaps.c: Got rid of dead old crud. diff --git a/src/paps.c b/src/paps.c index c4e64ef..d8e728f 100644 --- a/src/paps.c +++ b/src/paps.c @@ -418,7 +418,7 @@ split_text_into_paragraphs (PangoContext *pango_context, GList *result = NULL; char *last_para = text; - while (*p) + while (p != NULL && *p) { wc = g_utf8_get_char (p); next = g_utf8_next_char (p); -- cgit