diff options
author | Alexey Neyman <stilor@att.net> | 2016-11-10 01:35:27 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-11-10 01:35:27 (GMT) |
commit | a76c549823fd0063de999786b6dc583847db091e (patch) | |
tree | 04a51e165125497bbcb1b1d8865958c4cd14de5b /patches/glibc/2.9/380-2.3.6-dl_execstack-PaX-support.patch | |
parent | 23e9a03a3f4a5eaded6cadbe4d808997879450d1 (diff) | |
parent | dc280e477d6af7702e2481c17af20a7db83814d9 (diff) |
Merge pull request #452 from KirillSmirnov/janitorial
Janitorial: update patches
Diffstat (limited to 'patches/glibc/2.9/380-2.3.6-dl_execstack-PaX-support.patch')
-rw-r--r-- | patches/glibc/2.9/380-2.3.6-dl_execstack-PaX-support.patch | 71 |
1 files changed, 0 insertions, 71 deletions
diff --git a/patches/glibc/2.9/380-2.3.6-dl_execstack-PaX-support.patch b/patches/glibc/2.9/380-2.3.6-dl_execstack-PaX-support.patch deleted file mode 100644 index 0529e90..0000000 --- a/patches/glibc/2.9/380-2.3.6-dl_execstack-PaX-support.patch +++ /dev/null @@ -1,71 +0,0 @@ -Original patch from: gentoo/src/patchsets/glibc/2.9/3000_all_2.3.6-dl_execstack-PaX-support.patch - --= BEGIN original header =- - With latest versions of glibc, a lot of apps failed on a PaX enabled - system with: - cannot enable executable stack as shared object requires: Permission denied - - This is due to PaX 'exec-protecting' the stack, and ld.so then trying - to make the stack executable due to some libraries not containing the - PT_GNU_STACK section. Bug #32960. <azarah@gentoo.org> (12 Nov 2003). - - Patch also NPTL. Bug #116086. <kevquinn@gentoo.org> (20 Dec 2005). - --= END original header =- - -diff -durN glibc-2_9.orig/nptl/allocatestack.c glibc-2_9/nptl/allocatestack.c ---- glibc-2_9.orig/nptl/allocatestack.c 2008-08-16 00:35:27.000000000 +0200 -+++ glibc-2_9/nptl/allocatestack.c 2009-02-02 22:01:20.000000000 +0100 -@@ -299,7 +299,8 @@ - # error "Define either _STACK_GROWS_DOWN or _STACK_GROWS_UP" - #endif - if (mprotect (stack, len, PROT_READ | PROT_WRITE | PROT_EXEC) != 0) -- return errno; -+ if (errno != EACCES) /* PAX is enabled */ -+ return errno; - - return 0; - } -diff -durN glibc-2_9.orig/sysdeps/unix/sysv/linux/dl-execstack.c glibc-2_9/sysdeps/unix/sysv/linux/dl-execstack.c ---- glibc-2_9.orig/sysdeps/unix/sysv/linux/dl-execstack.c 2006-01-08 09:21:15.000000000 +0100 -+++ glibc-2_9/sysdeps/unix/sysv/linux/dl-execstack.c 2009-02-02 22:01:20.000000000 +0100 -@@ -63,7 +63,10 @@ - else - # endif - { -- result = errno; -+ if (errno == EACCES) /* PAX is enabled */ -+ result = 0; -+ else -+ result = errno; - goto out; - } - } -@@ -89,7 +92,12 @@ - page -= size; - else - { -- if (errno != ENOMEM) /* Unexpected failure mode. */ -+ if (errno == EACCES) /* PAX is enabled */ -+ { -+ result = 0; -+ goto out; -+ } -+ else if (errno != ENOMEM) /* Unexpected failure mode. */ - { - result = errno; - goto out; -@@ -115,7 +123,12 @@ - page += size; - else - { -- if (errno != ENOMEM) /* Unexpected failure mode. */ -+ if (errno == EACCES) /* PAX is enabled */ -+ { -+ result = 0; -+ goto out; -+ } -+ else if (errno != ENOMEM) /* Unexpected failure mode. */ - { - result = errno; - goto out; |