The branch, v3-0-test has been updated via d30efedfffd41a493c522642a8c95f4a5aafacab (commit) from 33bbefd492e9b0b873e47c032657db0c8e812c39 (commit)
http://gitweb.samba.org/?p=samba.git;a=shortlog;h=v3-0-test - Log ----------------------------------------------------------------- commit d30efedfffd41a493c522642a8c95f4a5aafacab Author: Björn Jacke <[EMAIL PROTECTED]> Date: Mon Apr 21 12:44:13 2008 +0200 fix alignment bug hitting Solaris with "reset in zero vc" activated ----------------------------------------------------------------------- Summary of changes: source/smbd/sesssetup.c | 13 ++++++++----- 1 files changed, 8 insertions(+), 5 deletions(-) Changeset truncated at 500 lines: diff --git a/source/smbd/sesssetup.c b/source/smbd/sesssetup.c index 378d8aa..0257cfa 100644 --- a/source/smbd/sesssetup.c +++ b/source/smbd/sesssetup.c @@ -1184,22 +1184,25 @@ static int reply_sesssetup_and_X_spnego(connection_struct *conn, char *inbuf, static int shutdown_other_smbds(TDB_CONTEXT *tdb, TDB_DATA kbuf, TDB_DATA dbuf, void *p) { - struct sessionid *sessionid = (struct sessionid *)dbuf.dptr; + struct sessionid sessionid; const char *ip = (const char *)p; - if (!process_exists(pid_to_procid(sessionid->pid))) { + SMB_ASSERT(dbuf.dsize == sizeof(sessionid)); + memcpy(&sessionid, dbuf.dptr, sizeof(sessionid)); + + if (!process_exists(pid_to_procid(sessionid.pid))) { return 0; } - if (sessionid->pid == sys_getpid()) { + if (sessionid.pid == sys_getpid()) { return 0; } - if (strcmp(ip, sessionid->ip_addr) != 0) { + if (strcmp(ip, sessionid.ip_addr) != 0) { return 0; } - message_send_pid(pid_to_procid(sessionid->pid), MSG_SHUTDOWN, + message_send_pid(pid_to_procid(sessionid.pid), MSG_SHUTDOWN, NULL, 0, True); return 0; } -- Samba Shared Repository