X-Git-Url: https://git.octo.it/?a=blobdiff_plain;f=src%2Fcommon.h;h=6b11b538db8a69ef001e7e7b28843d519d9ebe6b;hb=d6021a800b12c89b5a78877af2c5b9abc1a8e609;hp=425d6e2d6c5b74b729439be7be89b095b9e7c2d0;hpb=853b3da5d4c6614d7db4093f57b1ca4f57b6c485;p=collectd.git diff --git a/src/common.h b/src/common.h index 425d6e2d..6b11b538 100644 --- a/src/common.h +++ b/src/common.h @@ -278,15 +278,16 @@ int notification_init (notification_t *n, int severity, const char *message, const char *host, const char *plugin, const char *plugin_instance, const char *type, const char *type_instance); -#define NOTIFICATION_INIT_VL(n, vl, ds) \ +#define NOTIFICATION_INIT_VL(n, vl) \ notification_init (n, NOTIF_FAILURE, NULL, \ (vl)->host, (vl)->plugin, (vl)->plugin_instance, \ - (ds)->type, (vl)->type_instance) + (vl)->type, (vl)->type_instance) typedef int (*dirwalk_callback_f)(const char *dirname, const char *filename, void *user_data); int walk_directory (const char *dir, dirwalk_callback_f callback, void *user_data, int hidden); +/* Returns the number of bytes read or negative on error. */ int read_file_contents (const char *filename, char *buf, int bufsize); counter_t counter_diff (counter_t old_value, counter_t new_value);