changeset 549:4230e67bdfb1

exif_get_description_by_key(): tidy up.
author zas_
date Fri, 02 May 2008 22:31:24 +0000
parents 7ada6e5d4de8
children 00462776e9a2
files src/exif-common.c
diffstat 1 files changed, 3 insertions(+), 6 deletions(-) [+]
line wrap: on
line diff
--- a/src/exif-common.c	Fri May 02 22:28:39 2008 +0000
+++ b/src/exif-common.c	Fri May 02 22:31:24 2008 +0000
@@ -476,12 +476,9 @@
 
 	if (!key) return NULL;
 
-	i = 0;
-	while (ExifFormattedList[i].key != NULL)
-		{
-		if (strcmp(key, ExifFormattedList[i].key) == 0) return _(ExifFormattedList[i].description);
-		i++;
-		}
+	for (i = 0; ExifFormattedList[i].key; i++)
+		if (strcmp(key, ExifFormattedList[i].key) == 0)
+			return _(ExifFormattedList[i].description);
 
 	return exif_get_tag_description_by_key(key);
 }