diff --git a/src/bootchart/bootchart.c b/src/bootchart/bootchart.c index 9f99c1f6b..eadf17c35 100644 --- a/src/bootchart/bootchart.c +++ b/src/bootchart/bootchart.c @@ -346,8 +346,8 @@ int main(int argc, char *argv[]) { sampledata = new0(struct list_sample_data, 1); if (sampledata == NULL) { - log_error("Failed to allocate memory for a node: %m"); - return -1; + log_oom(); + return EXIT_FAILURE; } sampledata->sampletime = gettime_ns();