Initializing layout of osk to avoid undefined behavior when changing keyboards.
This commit is contained in:
parent
7e9990a6d6
commit
7bc0e2c157
1 changed files with 12 additions and 0 deletions
|
|
@ -214,6 +214,18 @@ static struct osk_layout *load_layout(on_screen_keyboard * keyboard, char *layou
|
||||||
|
|
||||||
layout = malloc(sizeof(osk_layout));
|
layout = malloc(sizeof(osk_layout));
|
||||||
layout->name = NULL;
|
layout->name = NULL;
|
||||||
|
layout->rows = NULL;
|
||||||
|
layout->width = 0;
|
||||||
|
layout->height = 0;
|
||||||
|
layout->fontpath = NULL;
|
||||||
|
layout->keys = NULL;
|
||||||
|
layout->keymap = NULL;
|
||||||
|
layout->composemap = NULL;
|
||||||
|
layout->keysymdefs = NULL;
|
||||||
|
layout->sizeofkeysymdefs = 0;
|
||||||
|
layout->bgcolor = def_bgcolor;
|
||||||
|
layout->fgcolor = def_fgcolor;
|
||||||
|
|
||||||
hlayout_loaded = 0;
|
hlayout_loaded = 0;
|
||||||
#ifdef DEBUG
|
#ifdef DEBUG
|
||||||
printf("load_layout %s\n", layout_name);
|
printf("load_layout %s\n", layout_name);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue