mirror of
https://gitlab.freedesktop.org/wayland/wayland.git
synced 2025-10-29 05:40:16 -04:00
cursor: remove unnecessary ifs in xcursor_load_theme
load_all_cursors_from_dir and xcursor_theme_inherits already have the NULL checks we want. Signed-off-by: Simon Ser <contact@emersion.fr>
This commit is contained in:
parent
6c49a8f7e5
commit
f33356742e
1 changed files with 5 additions and 10 deletions
|
|
@ -818,19 +818,14 @@ xcursor_load_theme(const char *theme, int size,
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
full = xcursor_build_fullname(dir, "cursors", "");
|
full = xcursor_build_fullname(dir, "cursors", "");
|
||||||
|
load_all_cursors_from_dir(full, size, load_callback,
|
||||||
if (full) {
|
user_data);
|
||||||
load_all_cursors_from_dir(full, size, load_callback,
|
free(full);
|
||||||
user_data);
|
|
||||||
free(full);
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!inherits) {
|
if (!inherits) {
|
||||||
full = xcursor_build_fullname(dir, "", "index.theme");
|
full = xcursor_build_fullname(dir, "", "index.theme");
|
||||||
if (full) {
|
inherits = xcursor_theme_inherits(full);
|
||||||
inherits = xcursor_theme_inherits(full);
|
free(full);
|
||||||
free(full);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
free(dir);
|
free(dir);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue