X-Git-Url: https://git.tokkee.org/?p=sysdb.git;a=blobdiff_plain;f=src%2Fcore%2Fplugin.c;h=0bf785d571a29b57ac9ecba7d9f34dd1dc6d6b5a;hp=76b0b1e45b656a6416bb8aa526581cd311ac5921;hb=bb7b99fec92dc9ea1c7ce70e050f4d97fec47ded;hpb=5cf58d25c37585bdc7aef79cfc899fdf5ba02ef2 diff --git a/src/core/plugin.c b/src/core/plugin.c index 76b0b1e..0bf785d 100644 --- a/src/core/plugin.c +++ b/src/core/plugin.c @@ -1733,8 +1733,10 @@ sdb_plugin_store_metric(const char *hostname, const char *name, metric.hostname = cname; metric.name = name; if (store) { - metric.store.type = store->type; - metric.store.id = store->id; + if (store->last_update < last_update) + store->last_update = last_update; + metric.stores = store; + metric.stores_num = 1; } metric.last_update = last_update ? last_update : sdb_gettime(); if (get_interval(SDB_METRIC, cname, -1, NULL, name,