[SCM] Samba Shared Repository - branch v3-2-test updated - initial-v3-2-unstable-455-gf04e37a

Jeremy Allison jra at samba.org
Tue Dec 4 20:53:58 GMT 2007


The branch, v3-2-test has been updated
       via  f04e37a630f8e7538d670d34db4ea7fc7c0b50a3 (commit)
      from  f1555f4f0d66e57fd19f200f842e4d05527accd5 (commit)

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


- Log -----------------------------------------------------------------
commit f04e37a630f8e7538d670d34db4ea7fc7c0b50a3
Author: Jeremy Allison <jra at samba.org>
Date:   Tue Dec 4 12:53:21 2007 -0800

    Fix crash bug with vl's new trans handling in old transs
    calls. Make this look like the (working) transs2 handling
    (replace inbuf, not write to outbuf - outbuf isn't allocated
    yet so you get a null deref).
    Jeremy.

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

Summary of changes:
 source/smbd/ipc.c |   11 ++++++-----
 1 files changed, 6 insertions(+), 5 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source/smbd/ipc.c b/source/smbd/ipc.c
index 0360417..eed293d 100644
--- a/source/smbd/ipc.c
+++ b/source/smbd/ipc.c
@@ -752,7 +752,7 @@ void reply_transs(connection_struct *conn, struct smb_request *req)
 			goto bad_param;
 
 		memcpy(state->data+ddisp, smb_base(req->inbuf)+doff,
-		       dcnt);      
+		       dcnt);
 	}
 
 	if ((state->received_param < state->total_param) ||
@@ -761,10 +761,11 @@ void reply_transs(connection_struct *conn, struct smb_request *req)
 		return;
 	}
 
-	/* construct_reply_common has done us the favor to pre-fill the
-	 * command field with SMBtranss which is wrong :-)
-	 */
-	SCVAL(req->outbuf,smb_com,SMBtrans);
+        /*
+	 * construct_reply_common will copy smb_com from inbuf to
+	 * outbuf. SMBtranss is wrong here.
+         */
+        SCVAL(req->inbuf,smb_com,SMBtrans);
 
 	handle_trans(conn, req, state);
 


-- 
Samba Shared Repository


More information about the samba-cvs mailing list