[mutter] backends-x11: Remove g_new0 overwriting g_object_new
- From: Jonas Ådahl <jadahl src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter] backends-x11: Remove g_new0 overwriting g_object_new
- Date: Thu, 11 Jun 2020 08:38:19 +0000 (UTC)
commit bad1a7fd0c13aaa1c817d3e54416e60a9e7b366d
Author: Daniel van Vugt <daniel van vugt canonical com>
Date: Thu Jun 11 14:17:16 2020 +0800
backends-x11: Remove g_new0 overwriting g_object_new
The object starts out right, and then gets overwritten with zeroes:
```
crtc_xrandr = g_object_new (META_TYPE_CRTC_XRANDR,
"id", crtc_id,
"gpu", gpu,
"all-transforms", all_transforms,
NULL);
crtc_xrandr = g_new0 (MetaCrtcXrandr, 1);
```
Closes: https://gitlab.gnome.org/GNOME/mutter/-/issues/1296
https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1306
src/backends/x11/meta-crtc-xrandr.c | 1 -
1 file changed, 1 deletion(-)
---
diff --git a/src/backends/x11/meta-crtc-xrandr.c b/src/backends/x11/meta-crtc-xrandr.c
index 0f17148752..b03e73c837 100644
--- a/src/backends/x11/meta-crtc-xrandr.c
+++ b/src/backends/x11/meta-crtc-xrandr.c
@@ -249,7 +249,6 @@ meta_crtc_xrandr_new (MetaGpuXrandr *gpu_xrandr,
"all-transforms", all_transforms,
NULL);
- crtc_xrandr = g_new0 (MetaCrtcXrandr, 1);
crtc_xrandr->transform =
meta_monitor_transform_from_xrandr (xrandr_crtc->rotation);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]