<div dir="ltr"><div><div>Hi,<br><br></div>this patch doesn't apply after 823ad33ef34fa32b14b300d987fb9d2e2a42e9c4 (src/evdev.c was deleted)</div>Otherwise looks OK<br><br>Reviewed-by: Marek Chalupa <<a href="mailto:mchqwerty@gmail.com">mchqwerty@gmail.com</a>><br><br><br>P. S. there is one more setting to NULL after calloc in src/compositor.c in weston_subsurface_create (sub->cached_buffer_ref.buffer = NULL)<br></div><div class="gmail_extra"><br><div class="gmail_quote">On 21 November 2014 at 07:21, Bryce Harrington <span dir="ltr"><<a href="mailto:bryce@osg.samsung.com" target="_blank">bryce@osg.samsung.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">calloc (and zalloc) set the allocated memory to 0, so there's really no<br>
need to do it manually.<br>
<br>
Signed-off-by: Bryce Harrington <<a href="mailto:bryce@osg.samsung.com">bryce@osg.samsung.com</a>><br>
---<br>
 src/compositor-fbdev.c |  4 ----<br>
 src/compositor.c       | 12 ------------<br>
 src/evdev.c            |  4 ----<br>
 src/gl-renderer.c      |  2 --<br>
 src/rpi-renderer.c     |  1 -<br>
 5 files changed, 23 deletions(-)<br>
<br>
diff --git a/src/compositor-fbdev.c b/src/compositor-fbdev.c<br>
index 138aaab..ccc017a 100644<br>
--- a/src/compositor-fbdev.c<br>
+++ b/src/compositor-fbdev.c<br>
@@ -533,10 +533,6 @@ fbdev_output_create(struct fbdev_compositor *compositor,<br>
        output->base.start_repaint_loop = fbdev_output_start_repaint_loop;<br>
        output->base.repaint = fbdev_output_repaint;<br>
        output->base.destroy = fbdev_output_destroy;<br>
-       output->base.assign_planes = NULL;<br>
-       output->base.set_backlight = NULL;<br>
-       output->base.set_dpms = NULL;<br>
-       output->base.switch_mode = NULL;<br>
<br>
        /* only one static mode in list */<br>
        output->mode.flags =<br>
diff --git a/src/compositor.c b/src/compositor.c<br>
index 72fe384..f19c33f 100644<br>
--- a/src/compositor.c<br>
+++ b/src/compositor.c<br>
@@ -440,10 +440,6 @@ weston_view_create(struct weston_surface *surface)<br>
        wl_list_init(&view->link);<br>
        wl_list_init(&view->layer_link.link);<br>
<br>
-       view->plane = NULL;<br>
-       view->layer_link.layer = NULL;<br>
-       view->parent_view = NULL;<br>
-<br>
        pixman_region32_init(&view->clip);<br>
        pixman_region32_init(&view->transform.masked_boundingbox);<br>
        pixman_region32_init(&view->transform.masked_opaque);<br>
@@ -459,8 +455,6 @@ weston_view_create(struct weston_surface *surface)<br>
        pixman_region32_init(&view->transform.boundingbox);<br>
        view->transform.dirty = 1;<br>
<br>
-       view->output = NULL;<br>
-<br>
        return view;<br>
 }<br>
<br>
@@ -617,8 +611,6 @@ weston_surface_create(struct weston_compositor *compositor)<br>
<br>
        wl_signal_init(&surface->destroy_signal);<br>
<br>
-       surface->resource = NULL;<br>
-<br>
        surface->compositor = compositor;<br>
        surface->ref_count = 1;<br>
<br>
@@ -629,10 +621,6 @@ weston_surface_create(struct weston_compositor *compositor)<br>
<br>
        weston_surface_state_init(&surface->pending);<br>
<br>
-       surface->output = NULL;<br>
-<br>
-       surface->viewport_resource = NULL;<br>
-<br>
        pixman_region32_init(&surface->damage);<br>
        pixman_region32_init(&surface->opaque);<br>
        region_init_infinite(&surface->input);<br>
diff --git a/src/evdev.c b/src/evdev.c<br>
index 888dfbd..078bc21 100644<br>
--- a/src/evdev.c<br>
+++ b/src/evdev.c<br>
@@ -638,14 +638,10 @@ evdev_device_create(struct weston_seat *seat, const char *path, int device_fd)<br>
<br>
        ec = seat->compositor;<br>
        device->seat = seat;<br>
-       device->seat_caps = 0;<br>
-       device->is_mt = 0;<br>
-       device->mtdev = NULL;<br>
        device->devnode = strdup(path);<br>
        device->mt.slot = -1;<br>
        device->rel.dx = 0;<br>
        device->rel.dy = 0;<br>
-       device->dispatch = NULL;<br>
        device->fd = device_fd;<br>
        device->pending_event = EVDEV_NONE;<br>
        wl_list_init(&device->link);<br>
diff --git a/src/gl-renderer.c b/src/gl-renderer.c<br>
index 076c242..677b43b 100644<br>
--- a/src/gl-renderer.c<br>
+++ b/src/gl-renderer.c<br>
@@ -1780,8 +1780,6 @@ gl_renderer_output_create(struct weston_output *output,<br>
        for (i = 0; i < BUFFER_DAMAGE_COUNT; i++)<br>
                pixman_region32_init(&go->buffer_damage[i]);<br>
<br>
-       go->buffer_damage_index = 0;<br>
-<br>
        output->renderer_state = go;<br>
<br>
        log_egl_config_info(gr->egl_display, egl_config);<br>
diff --git a/src/rpi-renderer.c b/src/rpi-renderer.c<br>
index c222eb6..4d0f522 100644<br>
--- a/src/rpi-renderer.c<br>
+++ b/src/rpi-renderer.c<br>
@@ -497,7 +497,6 @@ rpir_surface_create(struct rpi_renderer *renderer)<br>
                return NULL;<br>
<br>
        wl_list_init(&surface->views);<br>
-       surface->visible_views = 0;<br>
        surface->single_buffer = renderer->single_buffer;<br>
        surface->enable_opaque_regions = renderer->enable_opaque_regions;<br>
        rpi_resource_init(&surface->resources[0]);<br>
<span class="HOEnZb"><font color="#888888">--<br>
1.9.1<br>
<br>
_______________________________________________<br>
wayland-devel mailing list<br>
<a href="mailto:wayland-devel@lists.freedesktop.org">wayland-devel@lists.freedesktop.org</a><br>
<a href="http://lists.freedesktop.org/mailman/listinfo/wayland-devel" target="_blank">http://lists.freedesktop.org/mailman/listinfo/wayland-devel</a><br>
</font></span></blockquote></div><br></div>