From a8cff3a02a1aecdea2e4fecfa37dca809a176ec2 Mon Sep 17 00:00:00 2001
From: Matthew Barnes <mbarnes@redhat.com>
Date: Mon, 1 Sep 2008 14:57:02 +0000
Subject: Fix compiler warnings in some of the test programs.

2008-09-01  Matthew Barnes  <mbarnes@redhat.com>

	* configure.in:
	Fix compiler warnings in some of the test programs.

	* mail/em-composer-utils.c (edit_message):
	* plugins/email-custom-header/email-custom-header.c:
	* plugins/templates/templates.c:
	Don't mix declarations and code.


svn path=/trunk/; revision=36242
---
 mail/em-composer-utils.c | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

(limited to 'mail/em-composer-utils.c')

diff --git a/mail/em-composer-utils.c b/mail/em-composer-utils.c
index 8ae537ad7c..415a3d7193 100644
--- a/mail/em-composer-utils.c
+++ b/mail/em-composer-utils.c
@@ -822,6 +822,8 @@ edit_message (CamelMimeMessage *message, CamelFolder *drafts, const char *uid)
 		CamelStream *stream;		
 		CamelMimePart *part;
 		int count1 = 0, string_changed = 0;
+		const char *cur;
+		int i;
 
 		char *str;
 		gint count = 2;
@@ -853,14 +855,14 @@ edit_message (CamelMimeMessage *message, CamelFolder *drafts, const char *uid)
 		str = g_strndup ((const gchar*)((CamelStreamMem *) mem)->buffer->data, ((CamelStreamMem *) mem)->buffer->len);
 		camel_object_unref (mem);
 
-		const char *cur = str;
-		int i;
+		cur = str;
 		for (i = 0; i < strlen(str); i++) {
 			if (!g_ascii_strncasecmp (cur, "$", 1)) {
 				const char *end = cur, *check_env;
 				char *out;
 				GConfClient *gconf;
 				GSList *clue_list = NULL, *list;
+				char **temp_str;
 
 				gconf = gconf_client_get_default ();
 
@@ -870,7 +872,7 @@ edit_message (CamelMimeMessage *message, CamelFolder *drafts, const char *uid)
 				out = g_strndup ((const gchar *) cur, end - cur);
 				check_env = out;
 
-				char **temp_str = g_strsplit (str, out, 2);
+				temp_str = g_strsplit (str, out, 2);
 
 				/* Get the list from gconf */
 				clue_list = gconf_client_get_list ( gconf, GCONF_KEY_TEMPLATE_PLACEHOLDERS, GCONF_VALUE_STRING, NULL );
-- 
cgit