summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarsten Haitzler (Rasterman) <raster@rasterman.com>2014-05-12 17:37:04 +0900
committerThanatermesis <thanatermesis@gmail.com>2014-05-29 11:42:09 +0200
commit79e709d06d5f49dbcfd47cc1c6777f16b2d52953 (patch)
tree5c48ebc56933f1c80fb2df4d8d35ccf27843ed15
parenta1b479ee81bf8ab1d62d3ac0959bc7a2d3171d32 (diff)
downloadenlightenment-79e709d06d5f49dbcfd47cc1c6777f16b2d52953.tar.gz
enable ptrace of yama ptrace scope disabled on linux
this apparently re-enabled ptracing if the kernel says "nooo". @fix Conflicts: src/bin/e_main.c
-rw-r--r--src/bin/e_main.c18
1 files changed, 16 insertions, 2 deletions
diff --git a/src/bin/e_main.c b/src/bin/e_main.c
index ed58cfd8c8..00a74993a9 100644
--- a/src/bin/e_main.c
+++ b/src/bin/e_main.c
@@ -1,10 +1,15 @@
#include "e.h"
+
+#ifdef __linux__
+# include <sys/prctl.h>
+#endif
+
+#define MAX_LEVEL 80
+
#ifdef HAVE_ECORE_IMF
# include <Ecore_IMF.h>
#endif
-#define MAX_LEVEL 64
-
#define TS_DO
#ifdef TS_DO
# define TS(x) \
@@ -170,6 +175,15 @@ main(int argc, char **argv)
double t = 0.0, tstart = 0.0;
char *s = NULL, buff[32];
struct sigaction action;
+
+#ifdef __linux__
+# ifdef PR_SET_PTRACER
+# ifdef PR_SET_PTRACER_ANY
+ prctl(PR_SET_PTRACER, PR_SET_PTRACER_ANY);
+# endif
+# endif
+#endif
+
#ifdef TS_DO
t0 = t1 = t2 = ecore_time_unix_get();
#endif