*/
#ifndef VERSION
-#define VERSION "tig-0.4.git"
+#define VERSION "tig-0.5.git"
#endif
#ifndef DEBUG
static void
add_keybinding(enum keymap keymap, enum request request, int key)
{
- struct keybinding *keybinding = keybindings[keymap];
+ struct keybinding *keybinding;
- if (!keybinding)
- keybinding = calloc(1, sizeof(*keybinding));
+ keybinding = calloc(1, sizeof(*keybinding));
if (!keybinding)
die("Failed to allocate keybinding");
}
}
- if (status == CANCEL) {
- /* Clear the status window */
- status_empty = FALSE;
- report("");
+ /* Clear the status window */
+ status_empty = FALSE;
+ report("");
+
+ if (status == CANCEL)
return NULL;
- }
buf[pos++] = 0;
/* Refresh, accept single keystroke of input */
key = wgetch(status_win);
+ if (key == ERR)
+ continue;
request = get_keybinding(display[current_view]->keymap, key);