backport Avoid hangs when calling ldd.fakechroot with unknown arguments
This commit is contained in:
parent
cd1fe78094
commit
3f98b985d7
@ -0,0 +1,46 @@
|
|||||||
|
From d5e00bd29828468673420c552e7f027be8c43e02 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Alastair Hughes <hobbitalastair@gmail.com>
|
||||||
|
Date: Fri, 24 Aug 2018 21:57:44 +1200
|
||||||
|
Subject: [PATCH] Avoid hangs when calling ldd.fakechroot with unknown
|
||||||
|
arguments
|
||||||
|
|
||||||
|
---
|
||||||
|
scripts/ldd.fakechroot.pl | 12 ++++++------
|
||||||
|
1 file changed, 6 insertions(+), 6 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/scripts/ldd.fakechroot.pl b/scripts/ldd.fakechroot.pl
|
||||||
|
index a4dfe70..69c9b6c 100755
|
||||||
|
--- a/scripts/ldd.fakechroot.pl
|
||||||
|
+++ b/scripts/ldd.fakechroot.pl
|
||||||
|
@@ -155,11 +155,6 @@ sub load_ldsoconf {
|
||||||
|
MAIN: {
|
||||||
|
my @args = @ARGV;
|
||||||
|
|
||||||
|
- if (not @args) {
|
||||||
|
- print STDERR "fakeldd: missing file arguments\n";
|
||||||
|
- exit 1;
|
||||||
|
- }
|
||||||
|
-
|
||||||
|
if (not `sh -c 'command -v objdump'`) {
|
||||||
|
print STDERR "fakeldd: objdump: command not found: install binutils package\n";
|
||||||
|
exit 1;
|
||||||
|
@@ -170,10 +165,15 @@ MAIN: {
|
||||||
|
|
||||||
|
while ($args[0] =~ /^-/) {
|
||||||
|
my $arg = $args[0];
|
||||||
|
- shift @ARGV;
|
||||||
|
+ shift @args;
|
||||||
|
last if $arg eq "--";
|
||||||
|
}
|
||||||
|
|
||||||
|
+ if (not @args) {
|
||||||
|
+ print STDERR "fakeldd: missing file arguments\n";
|
||||||
|
+ exit 1;
|
||||||
|
+ }
|
||||||
|
+
|
||||||
|
foreach my $file (@args) {
|
||||||
|
%Libs = ();
|
||||||
|
$Dynamic = 0;
|
||||||
|
--
|
||||||
|
2.33.0
|
||||||
|
|
||||||
@ -1,12 +1,13 @@
|
|||||||
Name: fakechroot
|
Name: fakechroot
|
||||||
Version: 2.19
|
Version: 2.19
|
||||||
Release: 8
|
Release: 9
|
||||||
Summary: Gives a fake chroot environment
|
Summary: Gives a fake chroot environment
|
||||||
License: LGPLv2+
|
License: LGPLv2+
|
||||||
URL: https://github.com/dex4er/fakechroot
|
URL: https://github.com/dex4er/fakechroot
|
||||||
Source0: https://github.com/dex4er/fakechroot/archive/%{version}/fakechroot-%{version}.tar.gz
|
Source0: https://github.com/dex4er/fakechroot/archive/%{version}/fakechroot-%{version}.tar.gz
|
||||||
|
|
||||||
Patch0000: 0001-Add-support-of-LFS-compatible-fts-functions.patch
|
Patch0000: 0001-Add-support-of-LFS-compatible-fts-functions.patch
|
||||||
|
Patch0001: 0001-Avoid-hangs-when-calling-ldd.fakechroot-with-unknown.patch
|
||||||
|
|
||||||
Requires: binutils
|
Requires: binutils
|
||||||
Provides: fakechroot-libs = %{version}-%{release}
|
Provides: fakechroot-libs = %{version}-%{release}
|
||||||
@ -52,6 +53,9 @@ autoreconf -vfi
|
|||||||
%{_mandir}/man1/fakechroot.1*
|
%{_mandir}/man1/fakechroot.1*
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Fri Dec 22 2023 liyuanyuan <liyuanyuan@xfusion.com> - 2.19-9
|
||||||
|
- Avoid hangs when calling ldd.fakechroot with unknown arguments
|
||||||
|
|
||||||
* Wed Jan 22 2020 gulining<gulining1@huawei.com> - 2.19-8
|
* Wed Jan 22 2020 gulining<gulining1@huawei.com> - 2.19-8
|
||||||
- Disable test
|
- Disable test
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user