From: Volker Lendecke Date: Sat, 17 Jun 2017 19:26:27 +0000 (+0200) Subject: tevent: Simplify create_immediate X-Git-Tag: tevent-0.9.32~38 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a7504f555eff101a10ded653ceac98d8294c1659;p=thirdparty%2Fsamba.git tevent: Simplify create_immediate Not much change, just 9 lines less of code. Signed-off-by: Volker Lendecke Reviewed-by: Jeremy Allison --- diff --git a/lib/tevent/tevent.c b/lib/tevent/tevent.c index f3b18a15272..5f44b035e50 100644 --- a/lib/tevent/tevent.c +++ b/lib/tevent/tevent.c @@ -616,16 +616,7 @@ struct tevent_immediate *_tevent_create_immediate(TALLOC_CTX *mem_ctx, im = talloc(mem_ctx, struct tevent_immediate); if (im == NULL) return NULL; - im->prev = NULL; - im->next = NULL; - im->event_ctx = NULL; - im->create_location = location; - im->handler = NULL; - im->private_data = NULL; - im->handler_name = NULL; - im->schedule_location = NULL; - im->cancel_fn = NULL; - im->additional_data = NULL; + *im = (struct tevent_immediate) { .create_location = location }; return im; }