From af2fb66b89f82bf46b7fcd511c2bd6ebe7f950ef Mon Sep 17 00:00:00 2001 From: =?utf8?q?G=C3=BCnther=20Deschner?= Date: Mon, 27 Apr 2015 20:46:32 +0200 Subject: [PATCH] s3-spoolss: use talloc_zero in spoolss notify code MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Günther Deschner Reviewed-by: Andreas Schneider Autobuild-User(master): Andreas Schneider Autobuild-Date(master): Thu May 21 22:53:16 CEST 2015 on sn-devel-104 --- source3/printing/notify.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/source3/printing/notify.c b/source3/printing/notify.c index ec5f4705eb2..930e72b408a 100644 --- a/source3/printing/notify.c +++ b/source3/printing/notify.c @@ -357,12 +357,10 @@ static void send_notify_field_values(struct tevent_context *ev, if (!create_send_ctx()) return; - msg = talloc(send_ctx, struct spoolss_notify_msg); + msg = talloc_zero(send_ctx, struct spoolss_notify_msg); if (!msg) return; - ZERO_STRUCTP(msg); - fstrcpy(msg->printer, sharename); msg->type = type; msg->field = field; @@ -388,12 +386,10 @@ static void send_notify_field_buffer(struct tevent_context *ev, if (!create_send_ctx()) return; - msg = talloc(send_ctx, struct spoolss_notify_msg); + msg = talloc_zero(send_ctx, struct spoolss_notify_msg); if (!msg) return; - ZERO_STRUCTP(msg); - fstrcpy(msg->printer, sharename); msg->type = type; msg->field = field; -- 2.11.4.GIT