aboutsummaryrefslogtreecommitdiff
path: root/sway/commands/ipc.c
diff options
context:
space:
mode:
Diffstat (limited to 'sway/commands/ipc.c')
-rw-r--r--sway/commands/ipc.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/sway/commands/ipc.c b/sway/commands/ipc.c
index d49aab64..8a7b849f 100644
--- a/sway/commands/ipc.c
+++ b/sway/commands/ipc.c
@@ -14,6 +14,9 @@ struct cmd_results *cmd_ipc(int argc, char **argv) {
if ((error = checkarg(argc, "ipc", EXPECTED_EQUAL_TO, 2))) {
return error;
}
+ if ((error = check_security_config())) {
+ return error;
+ }
const char *program = argv[0];
@@ -26,11 +29,6 @@ struct cmd_results *cmd_ipc(int argc, char **argv) {
return cmd_results_new(CMD_FAILURE, "ipc", "Can only be used in config file.");
}
- if (!current_config_path || strcmp(SYSCONFDIR "/sway/security", current_config_path) != 0) {
- return cmd_results_new(CMD_INVALID, "permit",
- "This command is only permitted to run from " SYSCONFDIR "/sway/security");
- }
-
current_policy = alloc_ipc_policy(program);
list_add(config->ipc_policies, current_policy);