- notification_t n = {NOTIF_OKAY, cdtime(), "", "", MCELOG_PLUGIN,
- "", "", "", NULL};
- ssnprintf(n.message, sizeof(n.message), "Got memory errors info.");
- sstrncpy(n.type_instance, "memory_erros", sizeof(n.type_instance));
- if (mcelog_prepare_notification(&n, memory_record) == 0)
- mcelog_dispatch_notification(n);
- if (mcelog_submit(memory_record) != 0)
- ERROR("%s: Failed to submit memory errors", MCELOG_PLUGIN);
+ /* Check if location was successfully parsed */
+ if (memory_record.location[0] == '\0') {
+ memset(&memory_record, 0, sizeof(memory_record));
+ continue;
+ }
+
+ notification_t n = {.severity = NOTIF_OKAY,
+ .time = cdtime(),
+ .message = "Got memory errors info.",
+ .plugin = MCELOG_PLUGIN,
+ .type_instance = "memory_erros"};
+
+ if (mcelog_prepare_notification(&n, &memory_record) == 0)
+ mcelog_dispatch_notification(&n);
+ if (mcelog_submit(&memory_record) != 0)
+ ERROR(MCELOG_PLUGIN ": Failed to submit memory errors");