diff options
author | Daniel Teichmann <daniel.teichmann@das-netzwerkteam.de> | 2021-10-21 16:45:54 +0300 |
---|---|---|
committer | Daniel Teichmann <daniel.teichmann@das-netzwerkteam.de> | 2021-11-04 17:07:13 +0300 |
commit | 4a517102aed180d0359844466d8406e8fbdcf78f (patch) | |
tree | 5c56fb8cdd96f6fb853cb0c1001a177b88e13ffb | |
parent | c3b62c635eedc79a4cc33608efaa9a1e9fab623c (diff) |
x2go_plugin.c: Replace for-loop with g_strv_length() function.
-rw-r--r-- | plugins/x2go/x2go_plugin.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/plugins/x2go/x2go_plugin.c b/plugins/x2go/x2go_plugin.c index 315e3b776..4e0f6c515 100644 --- a/plugins/x2go/x2go_plugin.c +++ b/plugins/x2go/x2go_plugin.c @@ -1981,9 +1981,7 @@ static GError* rmplugin_x2go_string_setting_validator(gchar* key, gchar* value, gchar **elements_list = g_strsplit(data, ",", 0); guint elements_amount = 0; - for (; elements_list[elements_amount] != NULL; elements_amount++) { - // Just advance elements_amount... - } + elements_amount = g_strv_length(elements_list); if (elements_list == NULL || elements_list[0] == NULL || |