[SCM] Samba Shared Repository - branch v3-2-stable updated - release-3-2-0pre2-242-g1a59097

Karolin Seeger kseeger at samba.org
Fri Mar 28 15:04:07 GMT 2008


The branch, v3-2-stable has been updated
       via  1a59097946294d30e6fbd99c77021929f32a1557 (commit)
       via  fa47ae8880e08b968f530e602b0db4dd861de7e5 (commit)
       via  b9c19c5ff18c2c5383943193b31d72cd6c55a75b (commit)
      from  328c2282386079b94b65496b2f6b508044110b55 (commit)

http://gitweb.samba.org/?p=samba.git;a=shortlog;h=v3-2-stable


- Log -----------------------------------------------------------------
commit 1a59097946294d30e6fbd99c77021929f32a1557
Author: Volker Lendecke <vl at samba.org>
Date:   Thu Mar 27 22:54:10 2008 +0100

    Fix a memory leak
    (cherry picked from commit ce1bd43cdae63ff05aefaded419388e7b9e3ba9a)

commit fa47ae8880e08b968f530e602b0db4dd861de7e5
Author: Volker Lendecke <vl at samba.org>
Date:   Wed Mar 26 18:33:38 2008 +0100

    printclose has only 1 vwv
    (cherry picked from commit 99d980125054cbfef8ec85a31e83aa18a6e0bce3)

commit b9c19c5ff18c2c5383943193b31d72cd6c55a75b
Author: Volker Lendecke <vl at samba.org>
Date:   Fri Mar 28 15:21:14 2008 +0100

    More ssize_t->SMB_OFF_T
    (cherry picked from commit 8dd6458049d1b9d6849730ac19c39b049a68f302)

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

Summary of changes:
 source/client/client.c       |    2 +-
 source/lib/sharesec.c        |    2 ++
 source/libsmb/clireadwrite.c |   10 +++++-----
 source/smbd/reply.c          |    2 +-
 4 files changed, 9 insertions(+), 7 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source/client/client.c b/source/client/client.c
index cda5a6a..67e5030 100644
--- a/source/client/client.c
+++ b/source/client/client.c
@@ -981,7 +981,7 @@ static int do_get(const char *rname, const char *lname_in, bool reget)
 	uint16 attr;
 	SMB_OFF_T size;
 	off_t start = 0;
-	ssize_t nread = 0;
+	SMB_OFF_T nread = 0;
 	int rc = 0;
 	struct cli_state *targetcli = NULL;
 	char *targetname = NULL;
diff --git a/source/lib/sharesec.c b/source/lib/sharesec.c
index 5a8984f..2338cca 100644
--- a/source/lib/sharesec.c
+++ b/source/lib/sharesec.c
@@ -137,6 +137,8 @@ SEC_DESC *get_share_security( TALLOC_CTX *ctx, const char *servicename,
 
 	status = unmarshall_sec_desc(ctx, data.dptr, data.dsize, &psd);
 
+	SAFE_FREE(data.dptr);
+
 	if (!NT_STATUS_IS_OK(status)) {
 		DEBUG(0, ("unmarshall_sec_desc failed: %s\n",
 			  nt_errstr(status)));
diff --git a/source/libsmb/clireadwrite.c b/source/libsmb/clireadwrite.c
index f292fcb..668a269 100644
--- a/source/libsmb/clireadwrite.c
+++ b/source/libsmb/clireadwrite.c
@@ -191,7 +191,7 @@ struct cli_pull_state {
 	/*
 	 * For how many bytes did we send requests already?
 	 */
-	off_t requested;
+	SMB_OFF_T requested;
 
 	/*
 	 * Next request index to push into "sink". This walks around the "req"
@@ -205,7 +205,7 @@ struct cli_pull_state {
 	 * How many bytes did we push into "sink"?
 	 */
 
-	off_t pushed;
+	SMB_OFF_T pushed;
 };
 
 static char *cli_pull_print(TALLOC_CTX *mem_ctx, struct async_req *req)
@@ -412,7 +412,7 @@ static void cli_pull_read_done(struct async_req *read_req)
 	async_req_done(pull_req);
 }
 
-NTSTATUS cli_pull_recv(struct async_req *req, ssize_t *received)
+NTSTATUS cli_pull_recv(struct async_req *req, SMB_OFF_T *received)
 {
 	struct cli_pull_state *state = talloc_get_type_abort(
 		req->private_data, struct cli_pull_state);
@@ -428,7 +428,7 @@ NTSTATUS cli_pull_recv(struct async_req *req, ssize_t *received)
 NTSTATUS cli_pull(struct cli_state *cli, uint16_t fnum,
 		  off_t start_offset, SMB_OFF_T size, size_t window_size,
 		  NTSTATUS (*sink)(char *buf, size_t n, void *priv),
-		  void *priv, ssize_t *received)
+		  void *priv, SMB_OFF_T *received)
 {
 	TALLOC_CTX *frame = talloc_stackframe();
 	struct async_req *req;
@@ -466,7 +466,7 @@ ssize_t cli_read(struct cli_state *cli, int fnum, char *buf,
 		 off_t offset, size_t size)
 {
 	NTSTATUS status;
-	ssize_t ret;
+	SMB_OFF_T ret;
 
 	status = cli_pull(cli, fnum, offset, size, size,
 			  cli_read_sink, &buf, &ret);
diff --git a/source/smbd/reply.c b/source/smbd/reply.c
index 818ff31..b3f0fc5 100644
--- a/source/smbd/reply.c
+++ b/source/smbd/reply.c
@@ -4622,7 +4622,7 @@ void reply_printclose(struct smb_request *req)
 
 	START_PROFILE(SMBsplclose);
 
-	if (req->wct < 3) {
+	if (req->wct < 1) {
 		reply_nterror(req, NT_STATUS_INVALID_PARAMETER);
 		END_PROFILE(SMBsplclose);
 		return;


-- 
Samba Shared Repository


More information about the samba-cvs mailing list