mirror of
https://gitlab.freedesktop.org/wlroots/wlroots.git
synced 2025-11-02 09:01:38 -05:00
gamma-control-v1: fix fds not closed
This commit is contained in:
parent
2ae0575631
commit
bbd0fbe573
1 changed files with 3 additions and 1 deletions
|
|
@ -99,6 +99,8 @@ static void gamma_control_handle_set_gamma(struct wl_client *client,
|
||||||
gamma_control_send_failed(gamma_control);
|
gamma_control_send_failed(gamma_control);
|
||||||
goto error_table;
|
goto error_table;
|
||||||
}
|
}
|
||||||
|
close(fd);
|
||||||
|
fd = -1;
|
||||||
|
|
||||||
uint16_t *r = table;
|
uint16_t *r = table;
|
||||||
uint16_t *g = table + ramp_size;
|
uint16_t *g = table + ramp_size;
|
||||||
|
|
@ -109,8 +111,8 @@ static void gamma_control_handle_set_gamma(struct wl_client *client,
|
||||||
gamma_control_send_failed(gamma_control);
|
gamma_control_send_failed(gamma_control);
|
||||||
goto error_table;
|
goto error_table;
|
||||||
}
|
}
|
||||||
|
|
||||||
free(table);
|
free(table);
|
||||||
|
|
||||||
return;
|
return;
|
||||||
|
|
||||||
error_table:
|
error_table:
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue