summaryrefslogtreecommitdiff
path: root/src/plugins/demo
diff options
context:
space:
mode:
Diffstat (limited to 'src/plugins/demo')
-rw-r--r--src/plugins/demo/demo.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/src/plugins/demo/demo.c b/src/plugins/demo/demo.c
index 16c55323b..9b63e63a6 100644
--- a/src/plugins/demo/demo.c
+++ b/src/plugins/demo/demo.c
@@ -55,7 +55,7 @@ demo_print_list (void *list, char *item_name)
fields = weechat_list_fields (list);
if (fields)
{
- argv = weechat_string_explode (fields, ",", 0, &argc);
+ argv = weechat_string_explode (fields, ",", 0, 0, &argc);
if (argv && (argc > 0))
{
for (j = 0; j < argc; j++)
@@ -119,14 +119,15 @@ demo_buffer_infos ()
*/
static int
-demo_command (void *data, char *args)
+demo_command (void *data, int argc, char **argv, char **argv_eol)
{
/* make C compiler happy */
(void) data;
-
- if (args)
+ (void) argv_eol;
+
+ if (argc > 1)
{
- if (weechat_strcasecmp (args, "buffer") == 0)
+ if (weechat_strcasecmp (argv[1], "buffer") == 0)
{
demo_buffer_infos ();
return PLUGIN_RC_SUCCESS;