[Differential] [Commented On] D2003: Install a signal handler for SIGABRT and SIGSEGV for kwin_wayland
tcberner (Tobias C. Berner)
noreply at phabricator.kde.org
Sat Jun 25 17:55:47 UTC 2016
tcberner added inline comments.
INLINE COMMENTS
> bshah wrote in main_wayland.cpp:424-426
> This also need adaption for HAVE_PROC_TRACE_CTL perhaps? @tcberner can help us here maybe.
Sure, I will create a request as soon as I have some time to add it.
Btw, couldn't this be added as some function try_disable_ptrace() and try_enable_ptrace() or something of the form
int try_disable_ptrace()
{
#if HAVE_PR_SET_DUMPABLE
return prctl(PR_SET_DUMPABLE, 0);
#endif
#if HAVE_PROC_TRACE_CTL
int mode = PROC_TRACE_CTL_DISABLE;
return procctl(P_PID, getpid(), PROC_TRACE_CTL, &mode);
#endif
qWarning() << "Ptrace disabling not supported";
return -1;
}
int try_enable_ptrace()
{
#if HAVE_PR_SET_DUMPABLE
return prctl(PR_SET_DUMPABLE, 1);
#endif
#if HAVE_PROC_TRACE_CTL
int mode = PROC_TRACE_CTL_ENABLE;
return procctl(P_PID, getpid(), PROC_TRACE_CTL, &mode);
#endif
qWarning() << "Ptrace enabling not supported";
return -1;
}
and then just use these two functions everywhere instead of always retyping both?
REPOSITORY
rKWIN KWin
REVISION DETAIL
https://phabricator.kde.org/D2003
EMAIL PREFERENCES
https://phabricator.kde.org/settings/panel/emailpreferences/
To: graesslin, bshah, #kwin, #plasma_on_wayland
Cc: tcberner, plasma-devel, kwin, hardening, jensreuterberg, sebas
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/plasma-devel/attachments/20160625/97845637/attachment-0001.html>
More information about the Plasma-devel
mailing list