mirror of
https://gitlab.freedesktop.org/wlroots/wlroots.git
synced 2025-11-02 09:01:38 -05:00
treewide: Migrate from sizeof(struct) to sizeof(*pointer) where practical
This commit is contained in:
parent
a09d649439
commit
1b0694b794
99 changed files with 224 additions and 355 deletions
|
|
@ -252,7 +252,7 @@ static const struct zwlr_foreign_toplevel_handle_v1_listener toplevel_impl = {
|
|||
static void toplevel_manager_handle_toplevel(void *data,
|
||||
struct zwlr_foreign_toplevel_manager_v1 *toplevel_manager,
|
||||
struct zwlr_foreign_toplevel_handle_v1 *zwlr_toplevel) {
|
||||
struct toplevel_v1 *toplevel = calloc(1, sizeof(struct toplevel_v1));
|
||||
struct toplevel_v1 *toplevel = calloc(1, sizeof(*toplevel));
|
||||
if (!toplevel) {
|
||||
fprintf(stderr, "Failed to allocate memory for toplevel\n");
|
||||
return;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue