summaryrefslogtreecommitdiff
path: root/testing/systemd/0001-tmpfiles-restore-previous-behavior-for-F-f.patch
blob: 9be6ef28fb1d0219211e2bea1945a84020c7b281 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
From 1845fdd967d3a4c06f895413505de3c2429955b0 Mon Sep 17 00:00:00 2001
From: Dave Reisner <dreisner@archlinux.org>
Date: Thu, 27 Sep 2012 20:48:13 -0400
Subject: [PATCH] tmpfiles: restore previous behavior for F/f

d4e9eb91ea changed the behavior for the F and f actions, wrongly sending
them to glob_item(). Restore the old behavior and shortcut straight to
write_one_file().
---
 src/tmpfiles/tmpfiles.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/src/tmpfiles/tmpfiles.c b/src/tmpfiles/tmpfiles.c
index f10f908..bf900fa 100644
--- a/src/tmpfiles/tmpfiles.c
+++ b/src/tmpfiles/tmpfiles.c
@@ -673,6 +673,10 @@ static int create_item(Item *i) {
 
         case CREATE_FILE:
         case TRUNCATE_FILE:
+                r = write_one_file(i, i->path);
+                if (r < 0)
+                        return r;
+                break;
         case WRITE_FILE:
                 r = glob_item(i, write_one_file);
                 if (r < 0)
-- 
1.7.12.1