debug/io-stats: Handle loglevel in init

Change-Id: I5aa6ee7509a8f730ca64e2f7bada56d502785a6c
BUG: 3415
Reviewed-on: http://review.gluster.com/287
Reviewed-by: Raghavendra Bhat <raghavendrabhat@gluster.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
This commit is contained in:
Vijay Bellur 2011-08-21 17:46:57 +05:30
parent 5ace31ac21
commit af32ab6bc0

View File

@ -2398,6 +2398,8 @@ init (xlator_t *this)
int i = 0;
char *sys_log_str = NULL;
int sys_log_level = -1;
char *log_str = NULL;
int log_level = -1;
int ret = -1;
if (!this)
@ -2475,6 +2477,12 @@ init (xlator_t *this)
set_sys_log_level (sys_log_level);
}
GF_OPTION_INIT ("log-level", log_str, str, out);
if (log_str) {
log_level = glusterd_check_log_level (log_str);
gf_log_set_loglevel (log_level);
}
this->private = conf;
ret = 0;
out: