1
0
mirror of https://github.com/irssi/irssi.git synced 2024-09-01 04:14:16 -04:00

Replace g_strdup+g_str{up,down} with g_ascii_str{up,down}.

git-svn-id: http://svn.irssi.org/repos/irssi/trunk@4721 dbcabf3a-b0e7-0310-adc4-f8d773084564
This commit is contained in:
Emanuele Giaquinta 2008-03-04 10:42:23 +00:00 committed by exg
parent 40f7904a1a
commit af3b0b2b93
4 changed files with 4 additions and 8 deletions

View File

@ -254,9 +254,8 @@ static void cmd_help(const char *data)
{ {
char *cmd; char *cmd;
cmd = g_strdup(data); cmd = g_ascii_strdown(data, -1);
g_strchomp(cmd); g_strchomp(cmd);
g_strdown(cmd);
show_help(cmd); show_help(cmd);
g_free(cmd); g_free(cmd);
} }

View File

@ -138,8 +138,7 @@ static char **module_prefixes_get(void)
for (tmp = chat_protocols; tmp != NULL; tmp = tmp->next) { for (tmp = chat_protocols; tmp != NULL; tmp = tmp->next) {
CHAT_PROTOCOL_REC *rec = tmp->data; CHAT_PROTOCOL_REC *rec = tmp->data;
name = g_strdup(rec->name); name = g_ascii_strdown(rec->name, -1);
g_strdown(name);
list[count++] = name; list[count++] = name;
list[count++] = g_strconcat("fe_", name, NULL); list[count++] = g_strconcat("fe_", name, NULL);

View File

@ -58,8 +58,7 @@ void ctcp_register(const char *name)
rec = ctcp_cmd_find(name); rec = ctcp_cmd_find(name);
if (rec == NULL) { if (rec == NULL) {
rec = g_new0(CTCP_CMD_REC, 1); rec = g_new0(CTCP_CMD_REC, 1);
rec->name = g_strdup(name); rec->name = g_ascii_strup(name, -1);
g_strup(rec->name);
ctcp_cmds = g_slist_append(ctcp_cmds, rec); ctcp_cmds = g_slist_append(ctcp_cmds, rec);
} }

View File

@ -720,8 +720,7 @@ static void dcc_chat_msg(CHAT_DCC_REC *dcc, const char *msg)
ptr = strchr(cmd, ' '); ptr = strchr(cmd, ' ');
if (ptr != NULL) *ptr++ = '\0'; else ptr = ""; if (ptr != NULL) *ptr++ = '\0'; else ptr = "";
cmd = g_strdup(cmd); cmd = g_ascii_strup(cmd, -1);
g_strup(cmd);
g_strdown(event+9); g_strdown(event+9);
if (!signal_emit(event, 2, dcc, ptr)) { if (!signal_emit(event, 2, dcc, ptr)) {