svn commit: samba r21622 - in branches:
SAMBA_3_0/source/nsswitch SAMBA_3_0_25/source/nsswitch
SAMBA_3_0_RELEASE/source/nsswitch
SATOH Fumiyasu
fumiya at samba.gr.jp
Thu Mar 1 05:12:15 GMT 2007
At Thu, 1 Mar 2007 04:58:53 +0000 (GMT),
jerry at samba.org wrote:
> Author: jerry
> Date: 2007-03-01 04:58:52 +0000 (Thu, 01 Mar 2007)
> New Revision: 21622
>
> WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=21622
>
> Log:
> Fix bad merge caught by James.
Please apply the following patch too.
Index: SAMBA_3_0/source/nsswitch/winbindd_cred_cache.c
===================================================================
--- SAMBA_3_0/source/nsswitch/winbindd_cred_cache.c (revision 21622)
+++ SAMBA_3_0/source/nsswitch/winbindd_cred_cache.c (working copy)
@@ -517,6 +517,7 @@ static NTSTATUS store_memory_creds(struc
if ((mlock(memcredp->nt_hash, memcredp->len)) == -1) {
DEBUG(0,("failed to mlock memory: %s (%d)\n",
strerror(errno), errno));
+ SAFE_FREE(memcredp->nt_hash);
return map_nt_error_from_unix(errno);
}
--
-- Name: SATOH Fumiyasu / fumiyas @ osstech.co.jp
-- Business Home: http://www.OSSTech.co.jp
-- Personal Home: http://www.SFO.jp/blog/
> Modified:
> branches/SAMBA_3_0/source/nsswitch/winbindd_cred_cache.c
> branches/SAMBA_3_0_25/source/nsswitch/winbindd_cred_cache.c
> branches/SAMBA_3_0_RELEASE/source/nsswitch/winbindd_cred_cache.c
>
>
> Changeset:
> Modified: branches/SAMBA_3_0/source/nsswitch/winbindd_cred_cache.c
> ===================================================================
> --- branches/SAMBA_3_0/source/nsswitch/winbindd_cred_cache.c 2007-03-01 04:50:10 UTC (rev 21621)
> +++ branches/SAMBA_3_0/source/nsswitch/winbindd_cred_cache.c 2007-03-01 04:58:52 UTC (rev 21622)
> @@ -485,8 +485,6 @@
> #if !defined(HAVE_MLOCK)
> return NT_STATUS_OK;
> #else
> - int psize = getpagesize();
> -
> /* new_entry->nt_hash is the base pointer for the block
> of memory pointed into by new_entry->lm_hash and
> new_entry->pass (if we're storing plaintext). */
> @@ -506,11 +504,6 @@
> memcredp->nt_hash = SMB_MEMALIGN_ARRAY(unsigned char,
> getpagesize(), memcredp->len);
> #endif
> -
> - /* On non-linux platforms, mlock()'d memory must be aligned */
> -
> - memcredp->nt_hash = SMB_MEMALIGN_ARRAY(unsigned char, psize,
> - memcredp->len);
> if (!memcredp->nt_hash) {
> return NT_STATUS_NO_MEMORY;
> }
>
> Modified: branches/SAMBA_3_0_25/source/nsswitch/winbindd_cred_cache.c
> ===================================================================
> --- branches/SAMBA_3_0_25/source/nsswitch/winbindd_cred_cache.c 2007-03-01 04:50:10 UTC (rev 21621)
> +++ branches/SAMBA_3_0_25/source/nsswitch/winbindd_cred_cache.c 2007-03-01 04:58:52 UTC (rev 21622)
> @@ -485,8 +485,6 @@
> #if !defined(HAVE_MLOCK)
> return NT_STATUS_OK;
> #else
> - int psize = getpagesize();
> -
> /* new_entry->nt_hash is the base pointer for the block
> of memory pointed into by new_entry->lm_hash and
> new_entry->pass (if we're storing plaintext). */
> @@ -506,11 +504,6 @@
> memcredp->nt_hash = SMB_MEMALIGN_ARRAY(unsigned char,
> getpagesize(), memcredp->len);
> #endif
> -
> - /* On non-linux platforms, mlock()'d memory must be aligned */
> -
> - memcredp->nt_hash = SMB_MEMALIGN_ARRAY(unsigned char, psize,
> - memcredp->len);
> if (!memcredp->nt_hash) {
> return NT_STATUS_NO_MEMORY;
> }
>
> Modified: branches/SAMBA_3_0_RELEASE/source/nsswitch/winbindd_cred_cache.c
> ===================================================================
> --- branches/SAMBA_3_0_RELEASE/source/nsswitch/winbindd_cred_cache.c 2007-03-01 04:50:10 UTC (rev 21621)
> +++ branches/SAMBA_3_0_RELEASE/source/nsswitch/winbindd_cred_cache.c 2007-03-01 04:58:52 UTC (rev 21622)
> @@ -485,8 +485,6 @@
> #if !defined(HAVE_MLOCK)
> return NT_STATUS_OK;
> #else
> - int psize = getpagesize();
> -
> /* new_entry->nt_hash is the base pointer for the block
> of memory pointed into by new_entry->lm_hash and
> new_entry->pass (if we're storing plaintext). */
> @@ -506,11 +504,6 @@
> memcredp->nt_hash = SMB_MEMALIGN_ARRAY(unsigned char,
> getpagesize(), memcredp->len);
> #endif
> -
> - /* On non-linux platforms, mlock()'d memory must be aligned */
> -
> - memcredp->nt_hash = SMB_MEMALIGN_ARRAY(unsigned char, psize,
> - memcredp->len);
> if (!memcredp->nt_hash) {
> return NT_STATUS_NO_MEMORY;
> }
>
More information about the samba-technical
mailing list