mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-28 09:53:10 +00:00
4a429f5276
Fixes NixOS/nixos#135 and NixOS/nixos#126.
30 lines
966 B
Diff
30 lines
966 B
Diff
From f3838af51d461ca3d339618d17962f2d57d1a7fa Mon Sep 17 00:00:00 2001
|
|
From: Eelco Dolstra <eelco.dolstra@logicblox.com>
|
|
Date: Tue, 8 Jan 2013 15:45:01 +0100
|
|
Subject: [PATCH 2/8] Ignore duplicate paths in "systemctl start"
|
|
|
|
---
|
|
src/systemctl/systemctl.c | 6 ++++--
|
|
1 file changed, 4 insertions(+), 2 deletions(-)
|
|
|
|
diff --git a/src/systemctl/systemctl.c b/src/systemctl/systemctl.c
|
|
index fd9f580..b8252c9 100644
|
|
--- a/src/systemctl/systemctl.c
|
|
+++ b/src/systemctl/systemctl.c
|
|
@@ -1507,8 +1507,10 @@ static int start_unit_one(
|
|
r = set_put(s, p);
|
|
if (r < 0) {
|
|
free(p);
|
|
- log_error("Failed to add path to set.");
|
|
- return r;
|
|
+ if (r != -EEXIST) {
|
|
+ log_error("Failed to add path %s to set.", p);
|
|
+ return r;
|
|
+ }
|
|
}
|
|
}
|
|
|
|
--
|
|
1.8.1
|
|
|