diff options
Diffstat (limited to 'e-util')
-rw-r--r-- | e-util/ChangeLog | 4 | ||||
-rw-r--r-- | e-util/ename/e-name-western.c | 9 |
2 files changed, 9 insertions, 4 deletions
diff --git a/e-util/ChangeLog b/e-util/ChangeLog index 323a33051a..91663ac928 100644 --- a/e-util/ChangeLog +++ b/e-util/ChangeLog @@ -1,5 +1,9 @@ 2001-10-29 Christopher James Lahey <clahey@ximian.com> + * ename/e-name-western.c: Cleaned this up a bit. + +2001-10-29 Christopher James Lahey <clahey@ximian.com> + * ename/e-name-western.c (e_name_western_fixup): Check for compound first names here (X & Y). Fixes Ximian bug #13859. diff --git a/e-util/ename/e-name-western.c b/e-util/ename/e-name-western.c index 2628d742b8..e6bd333e3c 100644 --- a/e-util/ename/e-name-western.c +++ b/e-util/ename/e-name-western.c @@ -8,7 +8,7 @@ * Authors: * Nat Friedman <nat@ximian.com> * - * Copyright 1999, Ximian, Inc. + * Copyright 1999 - 2001, Ximian, Inc. */ #include <ctype.h> @@ -716,7 +716,9 @@ e_name_western_zap_nil (char **str, int *idx) char *new_last, *new_first; \ \ new_last = g_strdup (last_start + 1); \ - *last_start = 0; \ + *last_start = '\0'; \ + \ + idxs->last_idx += (last_start - name->last) + 1; \ \ new_first = g_strdup_printf ("%s %s %s", name->first, name->middle, name->last); \ \ @@ -729,7 +731,6 @@ e_name_western_zap_nil (char **str, int *idx) name->last = new_last; \ \ idxs->middle_idx = -1; \ - idxs->last_idx = idxs->first_idx + strlen (name->first) + 1; \ } else { \ char *new_first; \ \ @@ -833,7 +834,7 @@ e_name_western_fixup (ENameWestern *name, ENameWesternIdxs *idxs) /* Spanish */ CHECK_MIDDLE_NAME_FOR_CONJUNCTION_CASE ("y"); - /* German */ + /* German */ CHECK_MIDDLE_NAME_FOR_CONJUNCTION_CASE ("und"); /* Italian */ |