File: TransRead-hide-useless-message.patch

package info (click to toggle)
bmap-tools 3.6-2
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 936 kB
  • sloc: python: 5,078; sh: 117; makefile: 8
file content (33 lines) | stat: -rw-r--r-- 1,224 bytes parent folder | download
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
From: Artem Bityutskiy <artem.bityutskiy@linux.intel.com>
Date: Wed, 10 Mar 2021 15:33:48 +0200
Subject: TransRead: hide useless message

The previous patch (stop using 'subprocess.PIPE') addes a side-effect -
now we see 'tar' the following tar message:

tar: Removing leading `/' from member names'

This patch gets rid of them.

Origin: upstream, 3.7, commit:f41e5529471ff94fc84280338a0e13e4862daa63
Signed-off-by: Artem Bityutskiy <artem.bityutskiy@linux.intel.com>
---
 bmaptools/TransRead.py | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/bmaptools/TransRead.py b/bmaptools/TransRead.py
index cdfd37e..37bda8b 100644
--- a/bmaptools/TransRead.py
+++ b/bmaptools/TransRead.py
@@ -395,6 +395,11 @@ class TransRead(object):
                 self.size = os.fstat(self._f_objs[-1].fileno()).st_size
             return
 
+        if archiver == "tar":
+            # This will get rid of messages like:
+            #     tar: Removing leading `/' from member names'.
+            args += " -P -C /"
+
         # Make sure decompressor and the archiver programs are available
         if not BmapHelpers.program_is_available(decompressor):
             raise Error("the \"%s\" program is not available but it is "