diff options
author | Sebastien Helleu <flashcode@flashtux.org> | 2007-12-17 17:07:08 +0100 |
---|---|---|
committer | Sebastien Helleu <flashcode@flashtux.org> | 2007-12-17 17:07:08 +0100 |
commit | dba084f3d6a65ff8299c79b3867e28b57e50f1be (patch) | |
tree | 4b930f11254cc22148d7bd1b75eab83edcb1f063 /src/gui/gui-keyboard.c | |
parent | e62ec5204c7061a83860fa6c6c8204414a2dd057 (diff) | |
download | weechat-dba084f3d6a65ff8299c79b3867e28b57e50f1be.zip |
New backlog option in logger plugin, added variable names in .h files, replaced "void *" pointers by structures
Diffstat (limited to 'src/gui/gui-keyboard.c')
-rw-r--r-- | src/gui/gui-keyboard.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/gui/gui-keyboard.c b/src/gui/gui-keyboard.c index edc519042..3c52f729e 100644 --- a/src/gui/gui-keyboard.c +++ b/src/gui/gui-keyboard.c @@ -34,6 +34,7 @@ #include "../plugins/plugin.h" #include "gui-keyboard.h" #include "gui-action.h" +#include "gui-buffer.h" #include "gui-completion.h" #include "gui-input.h" #include "gui-window.h" @@ -244,7 +245,7 @@ gui_keyboard_get_internal_code (char *key) { char *result; - if ((result = (char *) malloc (strlen (key) + 1))) + if ((result = (char *)malloc (strlen (key) + 1))) { result[0] = '\0'; while (key[0]) @@ -287,7 +288,7 @@ gui_keyboard_get_expanded_name (char *key) { char *result; - if ((result = (char *) malloc ((strlen (key) * 5) + 1))) + if ((result = (char *)malloc ((strlen (key) * 5) + 1))) { result[0] = '\0'; while (key[0]) @@ -390,7 +391,7 @@ gui_keyboard_new (char *key, char *command, t_gui_key_func *function, char *args char *internal_code; int length; - if ((new_key = (t_gui_key *) malloc (sizeof (t_gui_key)))) + if ((new_key = (t_gui_key *)malloc (sizeof (t_gui_key)))) { internal_code = gui_keyboard_get_internal_code (key); new_key->key = (internal_code) ? strdup (internal_code) : strdup (key); @@ -750,7 +751,7 @@ gui_keyboard_buffer_reset () { gui_keyboard_buffer_alloc = GUI_KEYBOARD_BUFFER_BLOCK_SIZE; gui_keyboard_buffer_size = 0; - gui_keyboard_buffer = (int *) malloc (gui_keyboard_buffer_alloc); + gui_keyboard_buffer = (int *)malloc (gui_keyboard_buffer_alloc); } else { |