From 60ddf6284f59516154dccb3eabc7a45e9598cd22 Mon Sep 17 00:00:00 2001 From: Tobias Brunner Date: Tue, 29 Oct 2013 15:16:22 +0100 Subject: Use exact mask when calling umask(2) Due to the previous negation the high bits of the mask were set, which at least some versions of the Android build system prevent with a compile-time check. --- src/libcharon/plugins/smp/smp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/libcharon/plugins/smp/smp.c') diff --git a/src/libcharon/plugins/smp/smp.c b/src/libcharon/plugins/smp/smp.c index 7bc17008b..04bf382ed 100644 --- a/src/libcharon/plugins/smp/smp.c +++ b/src/libcharon/plugins/smp/smp.c @@ -767,7 +767,7 @@ plugin_t *smp_plugin_create() } unlink(unix_addr.sun_path); - old = umask(~(S_IRWXU | S_IRWXG)); + old = umask(S_IRWXO); if (bind(this->socket, (struct sockaddr *)&unix_addr, sizeof(unix_addr)) < 0) { DBG1(DBG_CFG, "could not bind XML socket: %s", strerror(errno)); -- cgit v1.2.3