xwayland: Fix memory allocation test
Due to a typo in tablet_pad_group(), we would allocate a variable
("group") and test another one ("pad") for allocation success.
Spotted by covscan.
Signed-off-by: Olivier Fourdan <ofourdan@redhat.com>
Fixes: commit 8475e63
- "xwayland: add tablet pad support"
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Michel Dänzer <mdaenzer@redhat.com>
This commit is contained in:
parent
138d4eba7b
commit
c01ac52b29
|
@ -2268,7 +2268,7 @@ tablet_pad_group(void *data,
|
||||||
struct xwl_tablet_pad_group *group;
|
struct xwl_tablet_pad_group *group;
|
||||||
|
|
||||||
group = calloc(1, sizeof *group);
|
group = calloc(1, sizeof *group);
|
||||||
if (pad == NULL) {
|
if (group == NULL) {
|
||||||
ErrorF("%s ENOMEM\n", __func__);
|
ErrorF("%s ENOMEM\n", __func__);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue