changeset 2058:0a1755f79392 HEAD

cleanup: str_*case(t_strdup_noconst(str)) -> t_str_*case(str)
author Timo Sirainen <tss@iki.fi>
date Tue, 25 May 2004 01:35:55 +0300
parents 5e0167577399
children 5847f9dc8ce4
files src/imap-login/client.c src/imap/client.c src/imap/imap-sort.c src/master/mail-process.c src/pop3-login/client.c src/pop3/commands.c
diffstat 6 files changed, 12 insertions(+), 12 deletions(-) [+]
line wrap: on
line diff
--- a/src/imap-login/client.c	Tue May 25 01:33:50 2004 +0300
+++ b/src/imap-login/client.c	Tue May 25 01:35:55 2004 +0300
@@ -168,7 +168,7 @@
 static int client_command_execute(struct imap_client *client, const char *cmd,
 				  struct imap_arg *args)
 {
-	cmd = str_ucase(t_strdup_noconst(cmd));
+	cmd = t_str_ucase(cmd);
 	if (strcmp(cmd, "LOGIN") == 0)
 		return cmd_login(client, args);
 	if (strcmp(cmd, "AUTHENTICATE") == 0)
--- a/src/imap/client.c	Tue May 25 01:33:50 2004 +0300
+++ b/src/imap/client.c	Tue May 25 01:35:55 2004 +0300
@@ -163,7 +163,7 @@
 	else if (client->cmd_name == NULL)
 		error = t_strconcat("BAD Error in IMAP command: ", msg, NULL);
 	else {
-		cmd = str_ucase(t_strdup_noconst(client->cmd_name));
+		cmd = t_str_ucase(client->cmd_name);
 		error = t_strconcat("BAD Error in IMAP command ",
 				    cmd, ": ", msg, NULL);
 	}
--- a/src/imap/imap-sort.c	Tue May 25 01:33:50 2004 +0300
+++ b/src/imap/imap-sort.c	Tue May 25 01:35:55 2004 +0300
@@ -313,7 +313,7 @@
 	if (ctx->common_mask & MAIL_SORT_CC) {
 		str = get_first_mailbox(mail, "cc");
 		if (str != NULL)
-			str = str_ucase(t_strdup_noconst(str));
+			str = t_str_ucase(str);
 
 		if (null_strcmp(str, ctx->last_cc) != 0) {
 			i_free(ctx->last_cc);
@@ -333,7 +333,7 @@
 	if (ctx->common_mask & MAIL_SORT_FROM) {
 		str = get_first_mailbox(mail, "from");
 		if (str != NULL)
-			str = str_ucase(t_strdup_noconst(str));
+			str = t_str_ucase(str);
 
 		if (null_strcmp(str, ctx->last_from) != 0) {
 			i_free(ctx->last_from);
@@ -367,7 +367,7 @@
 	if (ctx->common_mask & MAIL_SORT_TO) {
 		str = get_first_mailbox(mail, "to");
 		if (str != NULL)
-			str = str_ucase(t_strdup_noconst(str));
+			str = t_str_ucase(str);
 
 		if (null_strcmp(str, ctx->last_to) != 0) {
 			i_free(ctx->last_to);
@@ -430,7 +430,7 @@
 		else {
 			str = get_first_mailbox(mail, "cc");
 			if (str != NULL)
-				str = str_ucase(t_strdup_noconst(str));
+				str = t_str_ucase(str);
 		}
 		str = string_table_get(ctx, str);
 
@@ -444,7 +444,7 @@
 		else {
 			str = get_first_mailbox(mail, "from");
 			if (str != NULL)
-				str = str_ucase(t_strdup_noconst(str));
+				str = t_str_ucase(str);
 		}
 		str = string_table_get(ctx, str);
 
@@ -458,7 +458,7 @@
 		else {
 			str = get_first_mailbox(mail, "to");
 			if (str != NULL)
-				str = str_ucase(t_strdup_noconst(str));
+				str = t_str_ucase(str);
 		}
 		str = string_table_get(ctx, str);
 
@@ -592,7 +592,7 @@
 		}
 
 		if (str != NULL)
-			str = str_ucase(t_strdup_noconst(str));
+			str = t_str_ucase(str);
 		return str;
 	}
 
--- a/src/master/mail-process.c	Tue May 25 01:33:50 2004 +0300
+++ b/src/master/mail-process.c	Tue May 25 01:35:55 2004 +0300
@@ -95,7 +95,7 @@
 	tab[1].value = t_strcut(user, '@');
 	tab[2].value = strchr(user, '@');
 	if (tab[2].value != NULL) tab[2].value++;
-	tab[3].value = str_ucase(t_strdup_noconst(process_names[process_type]));
+	tab[3].value = t_str_ucase(process_names[process_type]);
 	tab[4].value = home;
 
 	return tab;
--- a/src/pop3-login/client.c	Tue May 25 01:33:50 2004 +0300
+++ b/src/pop3-login/client.c	Tue May 25 01:35:55 2004 +0300
@@ -113,7 +113,7 @@
 static int client_command_execute(struct pop3_client *client, const char *cmd,
 				  const char *args)
 {
-	cmd = str_ucase(t_strdup_noconst(cmd));
+	cmd = t_str_ucase(cmd);
 	if (strcmp(cmd, "CAPA") == 0)
 		return cmd_capa(client, args);
 	if (strcmp(cmd, "USER") == 0)
--- a/src/pop3/commands.c	Tue May 25 01:33:50 2004 +0300
+++ b/src/pop3/commands.c	Tue May 25 01:35:55 2004 +0300
@@ -431,7 +431,7 @@
 			    const char *name, const char *args)
 {
 	/* keep the command uppercased */
-	name = str_ucase(t_strdup_noconst(name));
+	name = t_str_ucase(name);
 
 	while (*args == ' ') args++;