From f14199d9c15a8062b5663fa6fcdae00390473b15 Mon Sep 17 00:00:00 2001 From: dequis Date: Tue, 7 Apr 2015 22:39:05 -0300 Subject: Change all strcmp() to g_strcmp0() to handle nulls gracefully Just a string replacement (but i did check every one of them) sed -i 's/strcmp(/g_strcmp0(/g' **/*.c --- src/core/commands.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/core/commands.c') diff --git a/src/core/commands.c b/src/core/commands.c index ed82f44e..9e451bc8 100644 --- a/src/core/commands.c +++ b/src/core/commands.c @@ -674,7 +674,7 @@ get_optional_channel(WI_ITEM_REC *active_item, char **data, int require_name) origtmp = tmp = g_strdup(*data); channel = cmd_get_param(&tmp); - if (strcmp(channel, "*") == 0 && !require_name) { + if (g_strcmp0(channel, "*") == 0 && !require_name) { /* "*" means active channel */ cmd_get_param(data); ret = window_item_get_target(active_item); -- cgit v1.2.3