From a9b6933ef097d2a81ce21a8aeda2acc569cd1509 Mon Sep 17 00:00:00 2001 From: Mohamed Ashiq Date: Tue, 19 May 2015 15:21:46 +0530 Subject: event,parse-utils,quota-common-utils,rbthash/libglusterfs : Porting to new logging framework Change-Id: I13ae9a97fe442c06cf50fe77c63718ea0858dc4d BUG: 1194640 Signed-off-by: Mohamed Ashiq Reviewed-on: http://review.gluster.org/10823 Tested-by: NetBSD Build System Reviewed-by: Pranith Kumar Karampuri --- libglusterfs/src/event-history.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'libglusterfs/src/event-history.c') diff --git a/libglusterfs/src/event-history.c b/libglusterfs/src/event-history.c index e89df09c935..95484a4322b 100644 --- a/libglusterfs/src/event-history.c +++ b/libglusterfs/src/event-history.c @@ -9,6 +9,7 @@ */ #include "event-history.h" +#include "libglusterfs-messages.h" eh_t * eh_new (size_t buffer_size, gf_boolean_t use_buffer_once, @@ -19,14 +20,12 @@ eh_new (size_t buffer_size, gf_boolean_t use_buffer_once, history = GF_CALLOC (1, sizeof (eh_t), gf_common_mt_eh_t); if (!history) { - gf_log ("", GF_LOG_ERROR, "allocating history failed."); goto out; } buffer = cb_buffer_new (buffer_size, use_buffer_once, destroy_buffer_data); if (!buffer) { - gf_log ("", GF_LOG_ERROR, "allocating circular buffer failed"); GF_FREE (history); history = NULL; goto out; @@ -44,7 +43,7 @@ eh_dump (eh_t *history, void *data, int (dump_fn) (circular_buffer_t *buffer, void *data)) { if (!history) { - gf_log ("", GF_LOG_DEBUG, "history is NULL"); + gf_msg_debug ("event-history", 0, "history is NULL"); goto out; } @@ -68,8 +67,8 @@ int eh_destroy (eh_t *history) { if (!history) { - gf_log ("", GF_LOG_INFO, "history for the xlator is " - "NULL"); + gf_msg ("event-history", GF_LOG_INFO, 0, LG_MSG_INVALID_ARG, + "history for the xlator is NULL"); return -1; } -- cgit