[SCM] Samba Shared Repository - branch master updated

Jeremy Allison jra at samba.org
Wed May 10 01:26:03 UTC 2017


The branch, master has been updated
       via  4ed1bfb dbwrap_ctdb: Fix a typo
       via  51ddb56 s3-gpo: Fix CID #1405972 Resource leak
       via  85e3d17 s4:tls: Do not use deprecated GnuTLS types
      from  cb17fcc s3-spoolss: add winreg_del_driver_package_internal()

https://git.samba.org/?p=samba.git;a=shortlog;h=master


- Log -----------------------------------------------------------------
commit 4ed1bfb9f854ce5d50e670d17d188745ed26edd3
Author: Volker Lendecke <vl at samba.org>
Date:   Mon May 8 12:16:16 2017 +0200

    dbwrap_ctdb: Fix a typo
    
    Signed-off-by: Volker Lendecke <vl at samba.org>
    Reviewed-by: Jeremy Allison <jra at samba.org>
    
    Autobuild-User(master): Jeremy Allison <jra at samba.org>
    Autobuild-Date(master): Wed May 10 03:25:40 CEST 2017 on sn-devel-144

commit 51ddb563ef7bd177cd7b08c41070e92dad3e3c82
Author: G√ľnther Deschner <gd at samba.org>
Date:   Tue May 9 14:31:15 2017 +0200

    s3-gpo: Fix CID #1405972 Resource leak
    
    Guenther
    
    Signed-off-by: Guenther Deschner <gd at samba.org>
    Reviewed-by: Jeremy Allison <jra at samba.org>

commit 85e3d1774cd069dc02a34850afc3c3df022eee91
Author: Andreas Schneider <asn at samba.org>
Date:   Tue May 9 13:17:13 2017 +0200

    s4:tls: Do not use deprecated GnuTLS types
    
    Those have been deprecated with GnuTLS 1.0.20 in 2004. I think it is
    safe to use them now ;)
    
    Signed-off-by: Andreas Schneider <asn at samba.org>
    Reviewed-by: Jeremy Allison <jra at samba.org>

-----------------------------------------------------------------------

Summary of changes:
 source3/lib/dbwrap/dbwrap_ctdb.c |  2 +-
 source3/libgpo/gpext/registry.c  |  1 +
 source4/lib/tls/tls.c            | 14 +++++++-------
 source4/lib/tls/tls_tstream.c    | 16 +++++++++-------
 4 files changed, 18 insertions(+), 15 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source3/lib/dbwrap/dbwrap_ctdb.c b/source3/lib/dbwrap/dbwrap_ctdb.c
index 10fe88d..7f61dec 100644
--- a/source3/lib/dbwrap/dbwrap_ctdb.c
+++ b/source3/lib/dbwrap/dbwrap_ctdb.c
@@ -1164,7 +1164,7 @@ again:
 		ctdb_time += timeval_elapsed(&ctdb_start_time);
 
 		if (ret != 0) {
-			DEBUG(5, ("ctdb_migrate failed: %s\n",
+			DEBUG(5, ("ctdbd_migrate failed: %s\n",
 				  strerror(ret)));
 			TALLOC_FREE(result);
 			return NULL;
diff --git a/source3/libgpo/gpext/registry.c b/source3/libgpo/gpext/registry.c
index 4a0d0cf..ceb05f0 100644
--- a/source3/libgpo/gpext/registry.c
+++ b/source3/libgpo/gpext/registry.c
@@ -342,6 +342,7 @@ static NTSTATUS registry_process_group_policy(TALLOC_CTX *mem_ctx,
 
 err_cache_path_free:
 	talloc_free(gpo_cache_path);
+	talloc_free(entries);
 	return status;
 }
 
diff --git a/source4/lib/tls/tls.c b/source4/lib/tls/tls.c
index ad8bbd4..ac4df22 100644
--- a/source4/lib/tls/tls.c
+++ b/source4/lib/tls/tls.c
@@ -39,8 +39,8 @@ typedef gnutls_datum gnutls_datum_t;
 
 /* hold persistent tls data */
 struct tls_params {
-	gnutls_certificate_credentials x509_cred;
-	gnutls_dh_params dh_params;
+	gnutls_certificate_credentials_t x509_cred;
+	gnutls_dh_params_t dh_params;
 	bool tls_enabled;
 	const char *tls_priority;
 };
@@ -52,14 +52,14 @@ struct tls_context {
 	struct tevent_fd *fde;
 	bool tls_enabled;
 #if ENABLE_GNUTLS
-	gnutls_session session;
+	gnutls_session_t session;
 	bool done_handshake;
 	bool have_first_byte;
 	uint8_t first_byte;
 	bool tls_detect;
 	const char *plain_chars;
 	bool output_pending;
-	gnutls_certificate_credentials xcred;
+	gnutls_certificate_credentials_t xcred;
 	bool interrupted;
 #endif
 };
@@ -111,7 +111,7 @@ static NTSTATUS tls_socket_init(struct socket_context *sock)
 /*
   callback for reading from a socket
 */
-static ssize_t tls_pull(gnutls_transport_ptr ptr, void *buf, size_t size)
+static ssize_t tls_pull(gnutls_transport_ptr_t ptr, void *buf, size_t size)
 {
 	struct tls_context *tls = talloc_get_type(ptr, struct tls_context);
 	NTSTATUS status;
@@ -150,7 +150,7 @@ static ssize_t tls_pull(gnutls_transport_ptr ptr, void *buf, size_t size)
 /*
   callback for writing to a socket
 */
-static ssize_t tls_push(gnutls_transport_ptr ptr, const void *buf, size_t size)
+static ssize_t tls_push(gnutls_transport_ptr_t ptr, const void *buf, size_t size)
 {
 	struct tls_context *tls = talloc_get_type(ptr, struct tls_context);
 	NTSTATUS status;
@@ -545,7 +545,7 @@ struct socket_context *tls_init_server(struct tls_params *params,
 					params->x509_cred));
 	gnutls_certificate_server_set_request(tls->session, GNUTLS_CERT_REQUEST);
 	gnutls_dh_set_prime_bits(tls->session, DH_BITS);
-	gnutls_transport_set_ptr(tls->session, (gnutls_transport_ptr)tls);
+	gnutls_transport_set_ptr(tls->session, (gnutls_transport_ptr_t)tls);
 	gnutls_transport_set_pull_function(tls->session, (gnutls_pull_func)tls_pull);
 	gnutls_transport_set_push_function(tls->session, (gnutls_push_func)tls_push);
 #if GNUTLS_VERSION_MAJOR < 3
diff --git a/source4/lib/tls/tls_tstream.c b/source4/lib/tls/tls_tstream.c
index 28fe332..9468971 100644
--- a/source4/lib/tls/tls_tstream.c
+++ b/source4/lib/tls/tls_tstream.c
@@ -85,7 +85,7 @@ struct tstream_tls {
 	int error;
 
 #if ENABLE_GNUTLS
-	gnutls_session tls_session;
+	gnutls_session_t tls_session;
 #endif /* ENABLE_GNUTLS */
 
 	enum tls_verify_peer_state verify_peer;
@@ -190,7 +190,7 @@ static void tstream_tls_push_trigger_write(struct tevent_context *ev,
 					   struct tevent_immediate *im,
 					   void *private_data);
 
-static ssize_t tstream_tls_push_function(gnutls_transport_ptr ptr,
+static ssize_t tstream_tls_push_function(gnutls_transport_ptr_t ptr,
 					 const void *buf, size_t size)
 {
 	struct tstream_context *stream =
@@ -329,7 +329,7 @@ static void tstream_tls_push_done(struct tevent_req *subreq)
 
 static void tstream_tls_pull_done(struct tevent_req *subreq);
 
-static ssize_t tstream_tls_pull_function(gnutls_transport_ptr ptr,
+static ssize_t tstream_tls_pull_function(gnutls_transport_ptr_t ptr,
 					 void *buf, size_t size)
 {
 	struct tstream_context *stream =
@@ -911,8 +911,8 @@ static const struct tstream_context_ops tstream_tls_ops = {
 
 struct tstream_tls_params {
 #if ENABLE_GNUTLS
-	gnutls_certificate_credentials x509_cred;
-	gnutls_dh_params dh_params;
+	gnutls_certificate_credentials_t x509_cred;
+	gnutls_dh_params_t dh_params;
 	const char *tls_priority;
 #endif /* ENABLE_GNUTLS */
 	bool tls_enabled;
@@ -1115,7 +1115,8 @@ struct tevent_req *_tstream_tls_connect_send(TALLOC_CTX *mem_ctx,
 		return tevent_req_post(req, ev);
 	}
 
-	gnutls_transport_set_ptr(tlss->tls_session, (gnutls_transport_ptr)state->tls_stream);
+	gnutls_transport_set_ptr(tlss->tls_session,
+				 (gnutls_transport_ptr_t)state->tls_stream);
 	gnutls_transport_set_pull_function(tlss->tls_session,
 					   (gnutls_pull_func)tstream_tls_pull_function);
 	gnutls_transport_set_push_function(tlss->tls_session,
@@ -1390,7 +1391,8 @@ struct tevent_req *_tstream_tls_accept_send(TALLOC_CTX *mem_ctx,
 					      GNUTLS_CERT_REQUEST);
 	gnutls_dh_set_prime_bits(tlss->tls_session, DH_BITS);
 
-	gnutls_transport_set_ptr(tlss->tls_session, (gnutls_transport_ptr)state->tls_stream);
+	gnutls_transport_set_ptr(tlss->tls_session,
+				 (gnutls_transport_ptr_t)state->tls_stream);
 	gnutls_transport_set_pull_function(tlss->tls_session,
 					   (gnutls_pull_func)tstream_tls_pull_function);
 	gnutls_transport_set_push_function(tlss->tls_session,


-- 
Samba Shared Repository



More information about the samba-cvs mailing list