Marcel Telka
2023-07-30 237c88fbda964150d9404655d4730298d6465bc4
userland-mangler: mangle_elf() needs write access

1 files modified
4 ■■■■ changed files
tools/userland-mangler 4 ●●●● patch | view | raw | blame | history
tools/userland-mangler
@@ -33,6 +33,7 @@
import re
import subprocess
import shutil
import stat
import pkg.fmri
@@ -272,6 +273,9 @@
                                # package instead of the new version.
                                shutil.copy2(src, dest)
                                # Make sure we do have write permission before we try to modify the file
                                os.chmod(dest, os.stat(dest).st_mode | stat.S_IWUSR)
                                # Mangle the copy by deleting the tag if there is nothing left to keep
                                # or replacing the value if there is something left.
                                elfcmd = "dyn:delete %s" % element.lower()