ports/x11/xcape/patches/patch-xcape_c

19 lines
425 B
Text
Raw Normal View History

2023-08-16 22:26:55 +00:00
pledge it
Index: xcape.c
--- xcape.c.orig
+++ xcape.c
@@ -191,6 +191,12 @@ int main (int argc, char **argv)
if (self->debug != True)
daemon (0, 0);
+ if (pledge ("stdio", NULL) == -1)
+ {
+ fprintf (stderr, "pledge: %s\n", strerror(errno));
+ exit (EXIT_FAILURE);
+ }
+
sigemptyset (&self->sigset);
sigaddset (&self->sigset, SIGINT);
sigaddset (&self->sigset, SIGTERM);