Compiling collectd-4.10.2 on an OpenSuSE 11.3 system causes the
following error:
snmp.c: In function ‘module_register’:
snmp.c:1620:3: error: passing argument 1 of ‘plugin_register_shutdown’ discards qualifiers from pointer target type
plugin.h:275:5: note: expected ‘char *’ but argument is of type ‘const char *’
Convert plugin_register_shutdown's name argument from 'char *' to
'const char *' in order to match the other plugin_register_*
functions.
Signed-off-by: Bruno Prémont <bonbons@linux-vserver.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
(void *) callback, ud));
} /* int plugin_register_flush */
-int plugin_register_shutdown (char *name,
+int plugin_register_shutdown (const char *name,
int (*callback) (void))
{
return (create_register_callback (&list_shutdown, name,
plugin_write_cb callback, user_data_t *user_data);
int plugin_register_flush (const char *name,
plugin_flush_cb callback, user_data_t *user_data);
-int plugin_register_shutdown (char *name,
+int plugin_register_shutdown (const char *name,
plugin_shutdown_cb callback);
int plugin_register_data_set (const data_set_t *ds);
int plugin_register_log (const char *name,