$OpenBSD: patch-src_keyevents_c,v 1.17 2018/03/17 08:30:09 landry Exp $
Index: src/keyevents.c
--- src/keyevents.c.orig
+++ src/keyevents.c
@@ -225,7 +225,7 @@ void init_keyevents(void) {
 
 	free(confpath);
 
-	if (!conf && ((conf = fopen("/etc/feh/keys", "r")) == NULL))
+	if (!conf && ((conf = fopen("${SYSCONFDIR}/feh/keys", "r")) == NULL))
 		return;
 
 	while (fgets(line, sizeof(line), conf)) {
@@ -390,7 +390,8 @@ void feh_event_handle_keypress(XEvent * ev)
 
 fehkey *feh_str_to_kb(char *action)
 {
-	for (unsigned int i = 0; i < EVENT_LIST_END; i++) {
+	unsigned int i;
+	for (i = 0; i < EVENT_LIST_END; i++) {
 		if (!strcmp(action, keys[i].name)) {
 			return &keys[i];
 		}
