aboutsummaryrefslogtreecommitdiffstats
path: root/e-util
diff options
context:
space:
mode:
authorChris Toshok <toshok@src.gnome.org>2000-05-08 09:48:28 +0800
committerChris Toshok <toshok@src.gnome.org>2000-05-08 09:48:28 +0800
commit9ce4dd5c57a5de7dace3059e3164cfd0f0e89044 (patch)
tree19973857d4625aa739f40cfac3e398c27684e677 /e-util
parent5aa0abfff8867dabcb22db7119709066b7120725 (diff)
downloadgsoc2013-evolution-9ce4dd5c57a5de7dace3059e3164cfd0f0e89044.tar
gsoc2013-evolution-9ce4dd5c57a5de7dace3059e3164cfd0f0e89044.tar.gz
gsoc2013-evolution-9ce4dd5c57a5de7dace3059e3164cfd0f0e89044.tar.bz2
gsoc2013-evolution-9ce4dd5c57a5de7dace3059e3164cfd0f0e89044.tar.lz
gsoc2013-evolution-9ce4dd5c57a5de7dace3059e3164cfd0f0e89044.tar.xz
gsoc2013-evolution-9ce4dd5c57a5de7dace3059e3164cfd0f0e89044.tar.zst
gsoc2013-evolution-9ce4dd5c57a5de7dace3059e3164cfd0f0e89044.zip
comment function, and fix an ABR.
* ename/e-name-western.c (e_name_western_extract_middle): comment function, and fix an ABR. svn path=/trunk/; revision=2894
Diffstat (limited to 'e-util')
-rw-r--r--e-util/ename/e-name-western.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/e-util/ename/e-name-western.c b/e-util/ename/e-name-western.c
index 755d7eabed..057afdacc1 100644
--- a/e-util/ename/e-name-western.c
+++ b/e-util/ename/e-name-western.c
@@ -300,13 +300,16 @@ e_name_western_extract_middle (ENameWestern *name, ENameWesternIdxs *idxs)
middle_idx = idxs->first_idx + strlen (name->first) + 1;
+ if (middle_idx > strlen (name->full))
+ return;
+
+ /*
+ * Search for the first space (or the terminating \0)
+ */
while (isspace (name->full [middle_idx]) &&
name->full [middle_idx] != '\0')
middle_idx ++;
- if (middle_idx > strlen (name->full))
- return;
-
if (name->full [middle_idx] == '\0')
return;