summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: e2541df)
raw | patch | inline | side by side (parent: e2541df)
author | Scott Sanders <scott@jssjr.com> | |
Sat, 1 Oct 2011 22:56:29 +0000 (18:56 -0400) | ||
committer | Scott Sanders <scott@jssjr.com> | |
Sat, 1 Oct 2011 22:56:29 +0000 (18:56 -0400) |
src/write_graphite.c | patch | blob | history |
diff --git a/src/write_graphite.c b/src/write_graphite.c
index 02ac696485079e2670c402e57ff3e84366631b51..42fb6950737abe22cb8a9e28b0724c8e1529e9bc 100644 (file)
--- a/src/write_graphite.c
+++ b/src/write_graphite.c
return (-1);
}
- if ((plugin_instance == NULL) || (strlen (plugin_instance) == 0))
+ if ((plugin_instance == NULL) || (plugin_instance[0] == '\0'))
{
- if ((type_instance == NULL) || (strlen (type_instance) == 0))
+ if ((type_instance == NULL) || (type_instance[0] == '\0'))
{
- if ((ds_name == NULL) || (strlen (ds_name) == 0))
+ if ((ds_name == NULL) || (ds_name[0] == '\0'))
status = ssnprintf (ret, ret_len, "%s.%s.%s.%s",
prefix, n_hostname, plugin, type);
else
}
else
{
- if ((ds_name == NULL) || (strlen (ds_name) == 0))
+ if ((ds_name == NULL) || (ds_name[0] == '\0'))
status = ssnprintf (ret, ret_len, "%s.%s.%s.%s-%s",
prefix, n_hostname, plugin, type,
type_instance);
}
else
{
- if ((type_instance == NULL) || (strlen (type_instance) == 0))
+ if ((type_instance == NULL) || (type_instance[0] == '\0'))
{
- if ((ds_name == NULL) || (strlen (ds_name) == 0))
+ if ((ds_name == NULL) || (ds_name[0] == '\0'))
status = ssnprintf (ret, ret_len, "%s.%s.%s.%s.%s",
prefix, n_hostname, plugin,
plugin_instance, type);
}
else
{
- if ((ds_name == NULL) || (strlen (ds_name) == 0))
+ if ((ds_name == NULL) || (ds_name[0] == '\0'))
status = ssnprintf (ret, ret_len, "%s.%s.%s.%s.%s-%s",
prefix, n_hostname, plugin,
plugin_instance, type, type_instance);