The branch, master has been updated via d7d1bb9 s3:smb2_create: add usefull DEBUG() message via 66fa891 s3:smbd/files: fsp->fnum is uint64_t not int! via bbad8f6 s3:brlock: s/int/uint64_t for fnum via c5f1ab9 s3:brlock: add some const to print_lock_struct() via a38d691 s3:wscript: use LOCKING subsystem for smbtorture3 from f80e399 source4/smbd/pidfile: don't panic if pid file is corrupt.
http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log ----------------------------------------------------------------- commit d7d1bb9444ab89c2fd922a8120eb5b21d06d0c54 Author: Stefan Metzmacher <me...@samba.org> Date: Thu Jun 28 10:02:01 2012 +0200 s3:smb2_create: add usefull DEBUG() message All calls which take an file handle have the same, so we should also log it, when we create a handle. metze Autobuild-User(master): Stefan Metzmacher <me...@samba.org> Autobuild-Date(master): Thu Jun 28 12:41:49 CEST 2012 on sn-devel-104 commit 66fa891d2d041652ecde02b53186802137ce3b02 Author: Stefan Metzmacher <me...@samba.org> Date: Thu Jun 28 10:00:37 2012 +0200 s3:smbd/files: fsp->fnum is uint64_t not int! metze commit bbad8f6d72f2be5bf3556c57e06d1ae604f1be36 Author: Stefan Metzmacher <me...@samba.org> Date: Thu Jun 28 09:54:41 2012 +0200 s3:brlock: s/int/uint64_t for fnum fsp->fnum and lock->fnum are uint64_t already and we should not truncate the value here. Currently this doesn't matter as we only use 16-bit. But as 'int' is int32_t and we later compare fnum with lock->fnum == fnum, the cast from int32_t to uint64_t goes via int64_t instead of uint32_t. This means even if fsp->fnum just uses 32-bit of the uint64_t we'll get the wrong result, as the implicit cast from a negative int32_t value to uint64_t adds 0xFFFFFFFF00000000. metze commit c5f1ab9a886104780ee65e43a5f36a3259df60f3 Author: Stefan Metzmacher <me...@samba.org> Date: Thu Jun 28 09:54:14 2012 +0200 s3:brlock: add some const to print_lock_struct() metze commit a38d6914af10ae18420b3400cf953292fd2699a5 Author: Stefan Metzmacher <me...@samba.org> Date: Thu Jun 28 00:51:45 2012 +0200 s3:wscript: use LOCKING subsystem for smbtorture3 metze ----------------------------------------------------------------------- Summary of changes: source3/locking/brlock.c | 4 ++-- source3/smbd/files.c | 6 +++--- source3/smbd/smb2_create.c | 3 +++ source3/wscript_build | 3 ++- 4 files changed, 10 insertions(+), 6 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/locking/brlock.c b/source3/locking/brlock.c index 7150936..efde599 100644 --- a/source3/locking/brlock.c +++ b/source3/locking/brlock.c @@ -46,7 +46,7 @@ static struct db_context *brlock_db; Debug info at level 10 for lock struct. ****************************************************************************/ -static void print_lock_struct(unsigned int i, struct lock_struct *pls) +static void print_lock_struct(unsigned int i, const struct lock_struct *pls) { DEBUG(10,("[%u]: smblctx = %llu, tid = %u, pid = %s, ", i, @@ -1487,7 +1487,7 @@ void brl_close_fnum(struct messaging_context *msg_ctx, { files_struct *fsp = br_lck->fsp; uint32_t tid = fsp->conn->cnum; - int fnum = fsp->fnum; + uint64_t fnum = fsp->fnum; unsigned int i; struct lock_struct *locks = br_lck->lock_data; struct server_id pid = messaging_server_id(fsp->conn->sconn->msg_ctx); diff --git a/source3/smbd/files.c b/source3/smbd/files.c index d11d6d7..b5be083 100644 --- a/source3/smbd/files.c +++ b/source3/smbd/files.c @@ -528,7 +528,7 @@ void fsp_free(files_struct *fsp) void file_free(struct smb_request *req, files_struct *fsp) { struct smbd_server_connection *sconn = fsp->conn->sconn; - int fnum = fsp->fnum; + uint64_t fnum = fsp->fnum; if (fsp->notify) { struct notify_context *notify_ctx = @@ -566,8 +566,8 @@ void file_free(struct smb_request *req, files_struct *fsp) fsp_free(fsp); - DEBUG(5,("freed files structure %d (%u used)\n", - fnum, (unsigned int)sconn->num_files)); + DEBUG(5,("freed files structure %llu (%u used)\n", + (unsigned long long)fnum, (unsigned int)sconn->num_files)); } /**************************************************************************** diff --git a/source3/smbd/smb2_create.c b/source3/smbd/smb2_create.c index f540377..b729ebf 100644 --- a/source3/smbd/smb2_create.c +++ b/source3/smbd/smb2_create.c @@ -826,6 +826,9 @@ static struct tevent_req *smbd_smb2_create_send(TALLOC_CTX *mem_ctx, state->out_file_id_volatile = result->fnum; state->out_context_blobs = out_context_blobs; + DEBUG(10,("smbd_smb2_create_send: %s - %s\n", + fsp_str_dbg(result), fsp_fnum_dbg(result))); + tevent_req_done(req); return tevent_req_post(req, ev); } diff --git a/source3/wscript_build b/source3/wscript_build index b8c1865..edb2f91 100755 --- a/source3/wscript_build +++ b/source3/wscript_build @@ -558,7 +558,7 @@ SMBTORTURE_SRC1 = '''torture/torture.c torture/nbio.c torture/scanner.c torture/ torture/test_idmap_tdb_common.c torture/t_strappend.c''' -SMBTORTURE_SRC = '''${SMBTORTURE_SRC1} ${LOCKING_SRC} ${FNAME_UTIL_SRC} +SMBTORTURE_SRC = '''${SMBTORTURE_SRC1} torture/wbc_async.c''' MASKTEST_SRC = '''torture/masktest.c''' @@ -1400,6 +1400,7 @@ bld.SAMBA3_BINARY('smbtorture' + bld.env.suffix3, TLDAP RPC_NDR_ECHO WB_REQTRANS + LOCKING NDR_OPEN_FILES idmap ''', -- Samba Shared Repository