summaryrefslogtreecommitdiffstats
path: root/meta/recipes-extended/logrotate/logrotate/disable-check-different-filesystems.patch
blob: 9ba531f815c0ccf78d3fd3432ea7a5d61cf45b31 (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
31
32
33
34
35
36
From a3fdf3dbdd6ecc0f2550a765dcb9bb274bce8ea8 Mon Sep 17 00:00:00 2001
From: Robert Yang <liezhi.yang@windriver.com>
Date: Tue, 8 Jan 2019 06:27:06 +0000
Subject: [PATCH] Disable the check for different filesystems

The logrotate supports rotate log across different filesystems now, so
disable the check for different filesystems.

Upstream-Status: Pending

Signed-off-by: Robert Yang <liezhi.yang@windriver.com>

---
 config.c | 9 ---------
 1 file changed, 9 deletions(-)

diff --git a/config.c b/config.c
index f027c7e..026136c 100644
--- a/config.c
+++ b/config.c
@@ -1873,15 +1873,6 @@ duperror:
                             }
 
                             free(ld);
-
-                            if (sb.st_dev != sb2.st_dev
-                                    && !(newlog->flags & (LOG_FLAG_COPYTRUNCATE | LOG_FLAG_COPY | LOG_FLAG_TMPFILENAME))) {
-                                message(MESS_ERROR,
-                                        "%s:%d olddir %s and log file %s "
-                                        "are on different devices\n", configFile,
-                                        lineNum, newlog->oldDir, newlog->files[i]);
-                                goto error;
-                            }
                         }
                     }