From f8f253aa29e3c2561d325cb47cc17a727f76266e Mon Sep 17 00:00:00 2001 From: Peter Verthez Date: Sun, 26 Jan 2003 18:37:24 +0000 Subject: [PATCH] Only try to delete address if present. --- bin/gedcom-sanitize.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/bin/gedcom-sanitize.c b/bin/gedcom-sanitize.c index 6439449..2698d41 100644 --- a/bin/gedcom-sanitize.c +++ b/bin/gedcom-sanitize.c @@ -90,9 +90,11 @@ int update_header() if (value != NULL) return 1; - result = gom_delete_address(&head->source.corporation.address); - if (result != 0) - return 1; + if (head->source.corporation.address) { + result = gom_delete_address(&head->source.corporation.address); + if (result != 0) + return 1; + } for (i=0; i<3; i++) { if (head->source.corporation.phone[i]) { -- 2.30.2