summaryrefslogtreecommitdiff
path: root/src/shared/util.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/shared/util.c')
-rw-r--r--src/shared/util.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/shared/util.c b/src/shared/util.c
index 2e7ae63db2..5f360085a2 100644
--- a/src/shared/util.c
+++ b/src/shared/util.c
@@ -909,8 +909,7 @@ int load_env_file(
continue;
if (!(u = normalize_env_assignment(p))) {
- log_error("Out of memory.");
- r = -ENOMEM;
+ r = log_oom();
goto finish;
}
@@ -918,8 +917,7 @@ int load_env_file(
free(u);
if (!t) {
- log_error("Out of memory.");
- r = -ENOMEM;
+ r = log_oom();
goto finish;
}
@@ -4278,7 +4276,7 @@ void execute_directory(const char *directory, DIR *d, char *argv[]) {
continue;
if (asprintf(&path, "%s/%s", directory, de->d_name) < 0) {
- log_error("Out of memory.");
+ log_oom();
continue;
}