diff --git a/src/core/store.c b/src/core/store.c
index a0bbf55ce39173c536c4758fce4efefcfeca81cf..3901ba45a3016b5d8ca5f911cee64cc33b6db388 100644 (file)
--- a/src/core/store.c
+++ b/src/core/store.c
if (old) {
if (old->host_last_update > last_update) {
if (old) {
if (old->host_last_update > last_update) {
- sdb_error_set(SDB_LOG_DEBUG, "store: Cannot update host '%s' - "
+ sdb_log(SDB_LOG_DEBUG, "store: Cannot update host '%s' - "
"value too old (%"PRIscTIME" < %"PRIscTIME")\n",
host->host_name, last_update, old->host_last_update);
/* don't report an error; the host may be updated by multiple
"value too old (%"PRIscTIME" < %"PRIscTIME")\n",
host->host_name, last_update, old->host_last_update);
/* don't report an error; the host may be updated by multiple
sdb_host_t *new = sdb_host_clone(host);
if (! new) {
char errbuf[1024];
sdb_host_t *new = sdb_host_clone(host);
if (! new) {
char errbuf[1024];
- sdb_error_set(SDB_LOG_ERR, "store: Failed to clone host object: "
+ sdb_log(SDB_LOG_ERR, "store: Failed to clone host object: "
"%s\n", sdb_strerror(errno, errbuf, sizeof(errbuf)));
pthread_rwlock_unlock(&host_lock);
return -1;
"%s\n", sdb_strerror(errno, errbuf, sizeof(errbuf)));
pthread_rwlock_unlock(&host_lock);
return -1;
if (! new->attributes) {
if (! (new->attributes = sdb_llist_create())) {
char errbuf[1024];
if (! new->attributes) {
if (! (new->attributes = sdb_llist_create())) {
char errbuf[1024];
- sdb_error_set(SDB_LOG_ERR, "store: Failed to initialize "
+ sdb_log(SDB_LOG_ERR, "store: Failed to initialize "
"host object '%s': %s\n", host->host_name,
sdb_strerror(errno, errbuf, sizeof(errbuf)));
sdb_object_deref(SDB_OBJ(new));
"host object '%s': %s\n", host->host_name,
sdb_strerror(errno, errbuf, sizeof(errbuf)));
sdb_object_deref(SDB_OBJ(new));
if (! new->services) {
if (! (new->services = sdb_llist_create())) {
char errbuf[1024];
if (! new->services) {
if (! (new->services = sdb_llist_create())) {
char errbuf[1024];
- sdb_error_set(SDB_LOG_ERR, "store: Failed to initialize "
+ sdb_log(SDB_LOG_ERR, "store: Failed to initialize "
"host object '%s': %s\n", host->host_name,
sdb_strerror(errno, errbuf, sizeof(errbuf)));
sdb_object_deref(SDB_OBJ(new));
"host object '%s': %s\n", host->host_name,
sdb_strerror(errno, errbuf, sizeof(errbuf)));
sdb_object_deref(SDB_OBJ(new));
if (old) {
if (old->host_last_update > last_update) {
if (old) {
if (old->host_last_update > last_update) {
- sdb_error_set(SDB_LOG_DEBUG, "store: Cannot update attribute "
+ sdb_log(SDB_LOG_DEBUG, "store: Cannot update attribute "
"'%s/%s' - value too old (%"PRIscTIME" < %"PRIscTIME")\n",
attr->hostname, attr->attr_name, last_update,
old->host_last_update);
"'%s/%s' - value too old (%"PRIscTIME" < %"PRIscTIME")\n",
attr->hostname, attr->attr_name, last_update,
old->host_last_update);
sdb_attribute_t *new = sdb_attribute_clone(attr);
if (! new) {
char errbuf[1024];
sdb_attribute_t *new = sdb_attribute_clone(attr);
if (! new) {
char errbuf[1024];
- sdb_error_set(SDB_LOG_ERR, "store: Failed to clone attribute "
+ sdb_log(SDB_LOG_ERR, "store: Failed to clone attribute "
"object: %s\n", sdb_strerror(errno, errbuf, sizeof(errbuf)));
pthread_rwlock_unlock(&host_lock);
return -1;
"object: %s\n", sdb_strerror(errno, errbuf, sizeof(errbuf)));
pthread_rwlock_unlock(&host_lock);
return -1;
if (old) {
if (old->host_last_update > last_update) {
if (old) {
if (old->host_last_update > last_update) {
- sdb_error_set(SDB_LOG_DEBUG, "store: Cannot update service "
+ sdb_log(SDB_LOG_DEBUG, "store: Cannot update service "
"'%s/%s' - value too old (%"PRIscTIME" < %"PRIscTIME")\n",
svc->hostname, svc->svc_name, last_update,
old->host_last_update);
"'%s/%s' - value too old (%"PRIscTIME" < %"PRIscTIME")\n",
svc->hostname, svc->svc_name, last_update,
old->host_last_update);
sdb_service_t *new = sdb_service_clone(svc);
if (! new) {
char errbuf[1024];
sdb_service_t *new = sdb_service_clone(svc);
if (! new) {
char errbuf[1024];
- sdb_error_set(SDB_LOG_ERR, "store: Failed to clone service "
+ sdb_log(SDB_LOG_ERR, "store: Failed to clone service "
"object: %s\n", sdb_strerror(errno, errbuf, sizeof(errbuf)));
pthread_rwlock_unlock(&host_lock);
return -1;
"object: %s\n", sdb_strerror(errno, errbuf, sizeof(errbuf)));
pthread_rwlock_unlock(&host_lock);
return -1;