diff options
author | Amar Tumballi <amar@gluster.com> | 2011-06-16 06:43:12 +0000 |
---|---|---|
committer | Anand Avati <avati@gluster.com> | 2011-06-16 22:02:13 -0700 |
commit | 0101eb0b6444dc22860d8fdc82170aefa87ff0b3 (patch) | |
tree | 83031b823600d1f905d36a15d26b427585c00cc1 /libglusterfs/src/common-utils.c | |
parent | 25e8700721a71128c9f6143dc2effcdbcee692fc (diff) |
logging: fill proper domain names at places where it is missing
also changed some error messages where it was not explicit
Signed-off-by: Amar Tumballi <amar@gluster.com>
Signed-off-by: Anand Avati <avati@gluster.com>
BUG: 2346 (Log message enhancements in GlusterFS - phase 1)
URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=2346
Diffstat (limited to 'libglusterfs/src/common-utils.c')
-rw-r--r-- | libglusterfs/src/common-utils.c | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/libglusterfs/src/common-utils.c b/libglusterfs/src/common-utils.c index 15371d194..96beee179 100644 --- a/libglusterfs/src/common-utils.c +++ b/libglusterfs/src/common-utils.c @@ -455,7 +455,7 @@ gf_strsplit (const char *str, const char *delim, int j = 0; if (str == NULL || delim == NULL || tokens == NULL || token_count == NULL) { - gf_log_callingfn ("", GF_LOG_WARNING, "arguement invalid"); + gf_log_callingfn (THIS->name, GF_LOG_WARNING, "arguement invalid"); return -1; } @@ -526,7 +526,7 @@ gf_strstr (const char *str, const char *delim, const char *match) tmp_str = strdup (str); if (str == NULL || delim == NULL || match == NULL || tmp_str == NULL) { - gf_log_callingfn ("", GF_LOG_WARNING, "arguement invalid"); + gf_log_callingfn (THIS->name, GF_LOG_WARNING, "arguement invalid"); ret = -1; goto out; } @@ -557,7 +557,7 @@ gf_volume_name_validate (const char *volume_name) const char *vname = NULL; if (volume_name == NULL) { - gf_log_callingfn ("", GF_LOG_WARNING, "arguement invalid"); + gf_log_callingfn (THIS->name, GF_LOG_WARNING, "arguement invalid"); return -1; } @@ -586,7 +586,7 @@ gf_string2time (const char *str, uint32_t *n) if (str == NULL || n == NULL) { - gf_log_callingfn ("", GF_LOG_WARNING, "arguement invalid"); + gf_log_callingfn (THIS->name, GF_LOG_WARNING, "arguement invalid"); errno = EINVAL; return -1; } @@ -641,7 +641,7 @@ gf_string2percent (const char *str, uint32_t *n) if (str == NULL || n == NULL) { - gf_log_callingfn ("", GF_LOG_WARNING, "arguement invalid"); + gf_log_callingfn (THIS->name, GF_LOG_WARNING, "arguement invalid"); errno = EINVAL; return -1; } @@ -694,7 +694,7 @@ _gf_string2long (const char *str, long *n, int base) if (str == NULL || n == NULL) { - gf_log_callingfn ("", GF_LOG_WARNING, "arguement invalid"); + gf_log_callingfn (THIS->name, GF_LOG_WARNING, "arguement invalid"); errno = EINVAL; return -1; } @@ -734,7 +734,7 @@ _gf_string2ulong (const char *str, unsigned long *n, int base) if (str == NULL || n == NULL) { - gf_log_callingfn ("", GF_LOG_WARNING, "arguement invalid"); + gf_log_callingfn (THIS->name, GF_LOG_WARNING, "arguement invalid"); errno = EINVAL; return -1; } @@ -789,7 +789,7 @@ _gf_string2uint (const char *str, unsigned int *n, int base) if (str == NULL || n == NULL) { - gf_log_callingfn ("", GF_LOG_WARNING, "arguement invalid"); + gf_log_callingfn (THIS->name, GF_LOG_WARNING, "arguement invalid"); errno = EINVAL; return -1; } @@ -842,7 +842,7 @@ _gf_string2double (const char *str, double *n) int old_errno = 0; if (str == NULL || n == NULL) { - gf_log_callingfn ("", GF_LOG_WARNING, "arguement invalid"); + gf_log_callingfn (THIS->name, GF_LOG_WARNING, "arguement invalid"); errno = EINVAL; return -1; } @@ -877,7 +877,7 @@ _gf_string2longlong (const char *str, long long *n, int base) if (str == NULL || n == NULL) { - gf_log_callingfn ("", GF_LOG_WARNING, "arguement invalid"); + gf_log_callingfn (THIS->name, GF_LOG_WARNING, "arguement invalid"); errno = EINVAL; return -1; } @@ -917,7 +917,7 @@ _gf_string2ulonglong (const char *str, unsigned long long *n, int base) if (str == NULL || n == NULL) { - gf_log_callingfn ("", GF_LOG_WARNING, "arguement invalid"); + gf_log_callingfn (THIS->name, GF_LOG_WARNING, "arguement invalid"); errno = EINVAL; return -1; } @@ -1308,7 +1308,7 @@ gf_string2bytesize (const char *str, uint64_t *n) if (str == NULL || n == NULL) { - gf_log_callingfn ("", GF_LOG_WARNING, "arguement invalid"); + gf_log_callingfn (THIS->name, GF_LOG_WARNING, "arguement invalid"); errno = EINVAL; return -1; } @@ -1419,7 +1419,7 @@ int gf_string2boolean (const char *str, gf_boolean_t *b) { if (str == NULL) { - gf_log_callingfn ("", GF_LOG_WARNING, "arguement invalid"); + gf_log_callingfn (THIS->name, GF_LOG_WARNING, "arguement invalid"); return -1; } @@ -1537,7 +1537,7 @@ get_checksum_for_path (char *path, uint32_t *checksum) fd = open (path, O_RDWR); if (fd == -1) { - gf_log ("", GF_LOG_ERROR, "Unable to open %s, errno: %d", + gf_log (THIS->name, GF_LOG_ERROR, "Unable to open %s, errno: %d", path, errno); goto out; } @@ -1666,7 +1666,7 @@ valid_internet_address (char *address) int length = 0; if (address == NULL) { - gf_log_callingfn ("", GF_LOG_WARNING, "arguement invalid"); + gf_log_callingfn (THIS->name, GF_LOG_WARNING, "arguement invalid"); goto out; } @@ -1762,7 +1762,7 @@ gf_is_str_int (const char *value) char *str = NULL; char *fptr = NULL; - GF_VALIDATE_OR_GOTO ("", value, out); + GF_VALIDATE_OR_GOTO (THIS->name, value, out); str = gf_strdup (value); if (!str) |