commit:     181718d12599fd379a5c0481bb335d933a7bd71e
Author:     Kerin Millar <kfm <AT> plushkava <DOT> net>
AuthorDate: Tue Jun 10 01:37:57 2025 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Wed Jun 11 03:26:22 2025 +0000
URL:        https://gitweb.gentoo.org/proj/portage.git/commit/?id=181718d1

estrip: drop the ed_noslash variables

Drop the 'ed_noslash' variable from the process_ar() and process_elf()
functions. It is useless.

Signed-off-by: Kerin Millar <kfm <AT> plushkava.net>
Signed-off-by: Sam James <sam <AT> gentoo.org>

 bin/estrip | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/bin/estrip b/bin/estrip
index 4b7f278ebe..7271733f8e 100755
--- a/bin/estrip
+++ b/bin/estrip
@@ -196,12 +196,11 @@ save_elf_debug() {
 process_elf() {
        local x=$1 inode_link=$2
        shift 2
-       local ed_noslash=${ED%/}
        local already_stripped xt_data
        local lockfile=${inode_link}_lockfile
        local locktries=100
 
-       __vecho "   ${x:${#ed_noslash}}"
+       __vecho "   ${x#"${ED%/}"}"
 
        # If two processes try to debugedit or strip the same hardlink at the
        # same time, it may corrupt files or cause loss of splitdebug info.
@@ -260,9 +259,8 @@ process_elf() {
 # Usage: process_ar <ar archive>
 process_ar() {
        local x=$1
-       local ed_noslash=${ED%/}
 
-       __vecho "   ${x:${#ed_noslash}}"
+       __vecho "   ${x#"${ED%/}"}"
 
        if (( do_strip )); then
                # If we have split debug enabled, then do not strip this.

Reply via email to