summaryrefslogtreecommitdiffstats
path: root/streaming/rrdpush.c
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2019-04-26 16:22:55 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2019-04-26 16:22:55 +0000
commitcaf1a5281f9e974ba73ceded3a782db3d0142c5f (patch)
treea09197b1fd2e984a0e8598e7007deb2a8e1969d7 /streaming/rrdpush.c
parentReleasing debian version 1.14.0~rc0-1. (diff)
downloadnetdata-caf1a5281f9e974ba73ceded3a782db3d0142c5f.tar.xz
netdata-caf1a5281f9e974ba73ceded3a782db3d0142c5f.zip
Merging upstream version 1.14.0.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'streaming/rrdpush.c')
-rw-r--r--streaming/rrdpush.c16
1 files changed, 9 insertions, 7 deletions
diff --git a/streaming/rrdpush.c b/streaming/rrdpush.c
index b98d0b3d..acf69ffd 100644
--- a/streaming/rrdpush.c
+++ b/streaming/rrdpush.c
@@ -151,13 +151,15 @@ static inline void rrdpush_send_chart_definition_nolock(RRDSET *st) {
// properly set the name for the remote end to parse it
char *name = "";
- if(unlikely(strcmp(st->id, st->name))) {
- // they differ
- name = strchr(st->name, '.');
- if(name)
- name++;
- else
- name = "";
+ if(likely(st->name)) {
+ if(unlikely(strcmp(st->id, st->name))) {
+ // they differ
+ name = strchr(st->name, '.');
+ if(name)
+ name++;
+ else
+ name = "";
+ }
}
// info("CHART '%s' '%s'", st->id, name);