aboutsummaryrefslogtreecommitdiff
path: root/src/skhd.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/skhd.c')
-rw-r--r--src/skhd.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/skhd.c b/src/skhd.c
index 6c08d45..e74715e 100644
--- a/src/skhd.c
+++ b/src/skhd.c
@@ -179,19 +179,23 @@ int main(int argc, char **argv)
}
if (!check_privileges()) {
- error("skhd: must be run with accessibility access.\n");
+ error("skhd: must be run with accessibility access! abort..\n");
}
if (!config_file) {
set_config_path();
}
+ printf("skhd: using config '%s'\n", config_file);
+
+ if (!initialize_keycode_map()) {
+ error("skhd: could not initialize keycode map! abort..\n");
+ }
table_init(&hotkey_map,
131,
(table_hash_func) hash_hotkey,
(table_compare_func) same_hotkey);
- printf("skhd: using config '%s'\n", config_file);
parse_config_helper(config_file);
signal(SIGCHLD, SIG_IGN);
@@ -204,6 +208,5 @@ int main(int argc, char **argv)
hotloader_begin(&hotloader, config_handler);
CFRunLoopRun();
-
return EXIT_SUCCESS;
}