1
0
mirror of https://github.com/irssi/irssi.git synced 2024-11-03 04:27:19 -05:00

If some keycombo can't be expanded, add it to state list as-is so it can use

existing combos given by GUI.


git-svn-id: http://svn.irssi.org/repos/irssi/trunk@2671 dbcabf3a-b0e7-0310-adc4-f8d773084564
This commit is contained in:
Timo Sirainen 2002-04-13 12:28:01 +00:00 committed by cras
parent 0d89364768
commit 607b440627

View File

@ -193,7 +193,7 @@ static int expand_combo(const char *start, const char *end, GSList **out)
KEY_REC *rec;
KEYINFO_REC *info;
GSList *tmp, *tmp2, *list, *copy, *newout;
char *str;
char *str, *p;
if (start == end) {
/* single key */
@ -214,10 +214,16 @@ static int expand_combo(const char *start, const char *end, GSList **out)
if (strcmp(rec->data, str) == 0)
list = g_slist_append(list, rec);
}
g_free(str);
if (list == NULL)
return FALSE;
if (list == NULL) {
/* unknown keycombo - add it as-is, maybe the GUI will
feed it to us as such */
for (p = str; *p != '\0'; p++)
expand_out_char(*out, *p);
g_free(str);
return TRUE;
}
g_free(str);
if (list->next == NULL) {
/* only one way to generate the combo, good */