Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 343064 Details for
Bug 457194
dev-libs/libffi-3.0.12 - test killed by PaX
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
libffi-3.0.13 emutramp pax patch
libffi-3.0.13-emutramp_pax.patch (text/plain), 1.71 KB, created by
Charles Svitlik
on 2013-03-24 05:26:30 UTC
(
hide
)
Description:
libffi-3.0.13 emutramp pax patch
Filename:
MIME Type:
Creator:
Charles Svitlik
Created:
2013-03-24 05:26:30 UTC
Size:
1.71 KB
patch
obsolete
>--- src/closures.c.orig 2013-03-24 01:18:11.513392828 -0400 >+++ src/closures.c 2013-03-24 01:18:25.519217731 -0400 >@@ -117,6 +117,7 @@ > #endif /* HAVE_MNTENT */ > #include <sys/param.h> > #include <pthread.h> >+#include <stdlib.h> > > /* We don't want sys/mman.h to be included after we redefine mmap and > dlmunmap. */ >@@ -125,7 +126,6 @@ > > #if FFI_MMAP_EXEC_SELINUX > #include <sys/statfs.h> >-#include <stdlib.h> > > static int selinux_enabled = -1; > >@@ -173,23 +173,39 @@ > #endif /* !FFI_MMAP_EXEC_SELINUX */ > > /* On PaX enable kernels that have MPROTECT enable we can't use PROT_EXEC. */ >-#ifdef FFI_MMAP_EXEC_EMUTRAMP_PAX >-#include <stdlib.h> >- >+#define LINE_BUFFER 1024 > static int emutramp_enabled = -1; >- >+static int pax_emutramp_enable = 0; > static int > emutramp_enabled_check (void) > { >- if (getenv ("FFI_DISABLE_EMUTRAMP") == NULL) >- return 1; >+ FILE *f; >+ char first[LINE_BUFFER], second[LINE_BUFFER], conf_line[LINE_BUFFER]; >+ f = fopen ("/proc/self/status", "r"); >+ if (f == NULL) >+#ifdef FFI_MMAP_EXEC_EMUTRAMP_PAX >+ pax_emutramp_enable = 1; >+#else >+ pax_emutramp_enable = 0; >+#endif > else >- return 0; >+ while (fgets (conf_line, LINE_BUFFER, f)) { >+ sscanf (conf_line, "%s %s", first, second); >+ if (!strncmp (first, "PaX:", 4)) { >+ if (second[1] == 'E') >+ pax_emutramp_enable = 1; >+ } >+ } >+ fclose(f); >+ if (pax_emutramp_enable) { >+ if (getenv ("FFI_DISABLE_EMUTRAMP") == NULL) >+ return 1; >+ } >+ return 0; > } > > #define is_emutramp_enabled() (emutramp_enabled >= 0 ? emutramp_enabled \ > : (emutramp_enabled = emutramp_enabled_check ())) >-#endif /* FFI_MMAP_EXEC_EMUTRAMP_PAX */ > > #elif defined (__CYGWIN__) || defined(__INTERIX) >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 457194
:
338826
|
338828
|
338946
| 343064 |
344008
|
346610
|
346832
|
346850