From 64e2a500f8e989da0b56ac7f7b6e2f4b844b9ec2 Mon Sep 17 00:00:00 2001 From: JP Rosevear Date: Wed, 20 Dec 2000 21:48:10 +0000 Subject: Check for null strings (e_pilot_utf8_from_pchar): ditto 2000-12-20 JP Rosevear * e-pilot-util.c (e_pilot_utf8_to_pchar): Check for null strings (e_pilot_utf8_from_pchar): ditto svn path=/trunk/; revision=7106 --- e-util/ChangeLog | 5 +++++ e-util/e-pilot-util.c | 6 ++++++ 2 files changed, 11 insertions(+) (limited to 'e-util') diff --git a/e-util/ChangeLog b/e-util/ChangeLog index acfa209e41..dbb96628d6 100644 --- a/e-util/ChangeLog +++ b/e-util/ChangeLog @@ -1,3 +1,8 @@ +2000-12-20 JP Rosevear + + * e-pilot-util.c (e_pilot_utf8_to_pchar): Check for null strings + (e_pilot_utf8_from_pchar): ditto + 2000-12-19 JP Rosevear * e-pilot-util.c (e_pilot_utf8_to_pchar): Convert utf8 strings to diff --git a/e-util/e-pilot-util.c b/e-util/e-pilot-util.c index 93bf9aa1b2..58c6937b8c 100644 --- a/e-util/e-pilot-util.c +++ b/e-util/e-pilot-util.c @@ -32,6 +32,9 @@ e_pilot_utf8_to_pchar (const char *string) { char *pstring = NULL; int res; + + if (!string) + return NULL; res = convert_ToPilotChar ("UTF8", string, strlen (string), &pstring); @@ -46,6 +49,9 @@ e_pilot_utf8_from_pchar (const char *string) { char *ustring = NULL; int res; + + if (!string) + return NULL; res = convert_FromPilotChar ("UTF8", string, strlen (string), &ustring); -- cgit