[SCM] Samba Shared Repository - branch master updated

2011-02-18 Thread Andrew Bartlett
The branch, master has been updated
   via  1ad8e52 lib/util/charset Add back setlocale(), but only when called 
from binaries
   via  2a3a86a lib/util/charcnv Move iconv handle setup in common
   via  5155a5f s3-charcnv Don't genreate valid_table on the fly, rely on 
valid.dat
   via  e4c2023 lib/util Remove #if _SAMBA_BUILD_ == 4 that isn't required 
any more
   via  8afc271 lib/util/charset Use top level iconv.c in source3
   via  bed3742 s4-idl: rename s4 server_id.idl to server_id4.idl
   via  cfeceed librpc make ndr-standard a common library
   via  177ddcb librpc push NDR_SECURITY and NDR_DCERPC to the top level 
wscript files
   via  a493bf9 nsswitch: depend on dl
   via  92faeae charset Remove use of {isupper,islower,toupper,tolower}_w 
functions
   via  0bad0e3 s3-libads Remove MIT-specific krb5_princ_realm macro calls.
   via  e4c2f5c s3-waf use lib/util/wscript_build, and avoid duplicate 
subsystems
   via  83a63ba lib/util Make UTIL_LDB conditional on an s4 build
   via  c8b2b10 s3-waf: use SAMBA3_*() build rules in source3/build
  from  e929223 build: put links for libs in the right directory

http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master


- Log -
commit 1ad8e5229f618fc04af371ba52b81f2e7e1f88f5
Author: Andrew Bartlett abart...@samba.org
Date:   Fri Feb 18 13:59:05 2011 +1100

lib/util/charset Add back setlocale(), but only when called from binaries

When called from a library, we don't want to call this, as we may
overwrite some of our calling program's context.

Andrew Bartlett

Autobuild-User: Andrew Bartlett abart...@samba.org
Autobuild-Date: Fri Feb 18 09:29:35 CET 2011 on sn-devel-104

commit 2a3a86a86f3d1ab97adda563beda7ee35f6a2414
Author: Andrew Bartlett abart...@samba.org
Date:   Fri Feb 18 13:47:28 2011 +1100

lib/util/charcnv Move iconv handle setup in common

We now use the struct smb_iconv_convenience at the core of all our
iconv code, and use global_iconv_convenience for the callers that
don't specify one.

Andrew Bartlett

commit 5155a5f5c130ff5b71ce4e37877378a6967046b4
Author: Andrew Bartlett abart...@samba.org
Date:   Fri Feb 18 11:51:33 2011 +1100

s3-charcnv Don't genreate valid_table on the fly, rely on valid.dat

This file is always installed, and is only even required for the old,
depricated mangle hash method.

Andrew Bartlett

commit e4c20230825dd78a2f06839dd7f6fe72f486a910
Author: Andrew Bartlett abart...@samba.org
Date:   Fri Feb 18 10:52:12 2011 +1100

lib/util Remove #if _SAMBA_BUILD_ == 4 that isn't required any more

commit 8afc271e2a9950fda68e99928746623093cbd6ac
Author: Andrew Bartlett abart...@samba.org
Date:   Fri Feb 18 10:24:58 2011 +1100

lib/util/charset Use top level iconv.c in source3

The two files were very similar already, the only change required was
to adopt the s3 module registration fucntion name.

(NTSTATUS wasn't used as the charset code does not otherwise use that
type).

Andrew Bartlett

Signed-off-by: Andrew Tridgell tri...@samba.org

commit bed374215ff040cc995659d42938be35412a794a
Author: Andrew Tridgell tri...@samba.org
Date:   Fri Feb 18 10:10:30 2011 +1100

s4-idl: rename s4 server_id.idl to server_id4.idl

this avoids a conflict with the new s3 server_id.idl

Pair-Programmed-With: Andrew Bartlett abart...@samba.org

commit cfeceedfab64fe8b7f5823d1ada3f6d9b1799adf
Author: Andrew Bartlett abart...@samba.org
Date:   Thu Feb 17 16:29:28 2011 +1100

librpc make ndr-standard a common library

commit 177ddcb084e8f8608bf2012a7c58f7b1e56d2acd
Author: Andrew Bartlett abart...@samba.org
Date:   Thu Feb 17 16:19:45 2011 +1100

librpc push NDR_SECURITY and NDR_DCERPC to the top level wscript files

There isn't any reson to keep these private to source3 and source4 and
more, and doing so creates problems for the top level build.

Andrew Bartlett

commit a493bf9103e5a36e0aef0d1bf1a055f602955d0f
Author: Andrew Tridgell tri...@samba.org
Date:   Thu Feb 17 14:13:42 2011 +1100

nsswitch: depend on dl

The previous merge in this area didn't preserve the 'dl' depedency,
which may be required on some platforms.

Pair-Programmed-With: Andrew Bartlett abart...@samba.org

commit 92faeaeea841dd0bce9460d25429846ae2fdc0af
Author: Andrew Bartlett abart...@samba.org
Date:   Wed Feb 16 16:30:56 2011 +1100

charset Remove use of {isupper,islower,toupper,tolower}_w functions

These now call the common _m functions that consider UTF16 code points.

This removes the code which will make up a 'lame' table in memory, as
this can just as correctly be handled by running the algorithm at runtime 
(which is to call toupper() and tolower() on characters  128).

When used, a top level waf build will always 

Re: [SCM] Samba Shared Repository - branch master updated

2011-02-18 Thread Jelmer Vernooij
On Fri, 2011-02-18 at 09:30 +0100, Andrew Bartlett wrote:
 - Log -
 commit 1ad8e5229f618fc04af371ba52b81f2e7e1f88f5
 Author: Andrew Bartlett abart...@samba.org
 Date:   Fri Feb 18 13:59:05 2011 +1100
 
 lib/util/charset Add back setlocale(), but only when called from binaries
 
 When called from a library, we don't want to call this, as we may
 overwrite some of our calling program's context.
What in particular re-added the need for this? 

I'm worried about this change as it means we won't be testing the
library code that e.g. gets used as part of OpenChange and Evolution.

It would be really nice if we could get rid of our reliance on the
system locale for once and for all. :-/

Cheers,

Jelmer


 commit 2a3a86a86f3d1ab97adda563beda7ee35f6a2414
 Author: Andrew Bartlett abart...@samba.org
 Date:   Fri Feb 18 13:47:28 2011 +1100
 
 lib/util/charcnv Move iconv handle setup in common
 
 We now use the struct smb_iconv_convenience at the core of all our
 iconv code, and use global_iconv_convenience for the callers that
 don't specify one.
 
 Andrew Bartlett
 
 commit 5155a5f5c130ff5b71ce4e37877378a6967046b4
 Author: Andrew Bartlett abart...@samba.org
 Date:   Fri Feb 18 11:51:33 2011 +1100
 
 s3-charcnv Don't genreate valid_table on the fly, rely on valid.dat
 
 This file is always installed, and is only even required for the old,
 depricated mangle hash method.
 
 Andrew Bartlett
 
 commit e4c20230825dd78a2f06839dd7f6fe72f486a910
 Author: Andrew Bartlett abart...@samba.org
 Date:   Fri Feb 18 10:52:12 2011 +1100
 
 lib/util Remove #if _SAMBA_BUILD_ == 4 that isn't required any more
 
 commit 8afc271e2a9950fda68e99928746623093cbd6ac
 Author: Andrew Bartlett abart...@samba.org
 Date:   Fri Feb 18 10:24:58 2011 +1100
 
 lib/util/charset Use top level iconv.c in source3
 
 The two files were very similar already, the only change required was
 to adopt the s3 module registration fucntion name.
 
 (NTSTATUS wasn't used as the charset code does not otherwise use that
 type).
 
 Andrew Bartlett
 
 Signed-off-by: Andrew Tridgell tri...@samba.org
 
 commit bed374215ff040cc995659d42938be35412a794a
 Author: Andrew Tridgell tri...@samba.org
 Date:   Fri Feb 18 10:10:30 2011 +1100
 
 s4-idl: rename s4 server_id.idl to server_id4.idl
 
 this avoids a conflict with the new s3 server_id.idl
 
 Pair-Programmed-With: Andrew Bartlett abart...@samba.org
 
 commit cfeceedfab64fe8b7f5823d1ada3f6d9b1799adf
 Author: Andrew Bartlett abart...@samba.org
 Date:   Thu Feb 17 16:29:28 2011 +1100
 
 librpc make ndr-standard a common library
 
 commit 177ddcb084e8f8608bf2012a7c58f7b1e56d2acd
 Author: Andrew Bartlett abart...@samba.org
 Date:   Thu Feb 17 16:19:45 2011 +1100
 
 librpc push NDR_SECURITY and NDR_DCERPC to the top level wscript files
 
 There isn't any reson to keep these private to source3 and source4 and
 more, and doing so creates problems for the top level build.
 
 Andrew Bartlett
 
 commit a493bf9103e5a36e0aef0d1bf1a055f602955d0f
 Author: Andrew Tridgell tri...@samba.org
 Date:   Thu Feb 17 14:13:42 2011 +1100
 
 nsswitch: depend on dl
 
 The previous merge in this area didn't preserve the 'dl' depedency,
 which may be required on some platforms.
 
 Pair-Programmed-With: Andrew Bartlett abart...@samba.org
 
 commit 92faeaeea841dd0bce9460d25429846ae2fdc0af
 Author: Andrew Bartlett abart...@samba.org
 Date:   Wed Feb 16 16:30:56 2011 +1100
 
 charset Remove use of {isupper,islower,toupper,tolower}_w functions
 
 These now call the common _m functions that consider UTF16 code points.
 
 This removes the code which will make up a 'lame' table in memory, as
 this can just as correctly be handled by running the algorithm at runtime 
 (which is to call toupper() and tolower() on characters  128).
 
 When used, a top level waf build will always locate the correct table
 - in the build tree or outside - due to relinking the installed
 binary.
 
 Andrew Bartlett
 
 commit 0bad0e3ff2063f009557ab6ad7a442ceaed593ee
 Author: Andrew Bartlett abart...@samba.org
 Date:   Tue Feb 15 16:34:02 2011 +1100
 
 s3-libads Remove MIT-specific krb5_princ_realm macro calls.
 
 When compiled against heimdal, we need to use a more elegant API.
 
 Andrew Bartlett
 
 commit e4c2f5c474b2c294341edcce8044319a111e1e45
 Author: Andrew Bartlett abart...@samba.org
 Date:   Fri Feb 18 16:04:30 2011 +1100
 
 s3-waf use lib/util/wscript_build, and avoid duplicate subsystems
 
 commit 83a63baecc0b49dac5547551436f9fca2595f2f7
 Author: Andrew Bartlett abart...@samba.org
 Date:   Thu Feb 17 16:39:07 2011 +1100
 
 lib/util Make UTIL_LDB conditional on an s4 build
 
 This allows this file to be used in common.
 
 commit 

[SCM] Samba Shared Repository - branch master updated

2011-02-18 Thread Günther Deschner
The branch, master has been updated
   via  927792b s3-smbsharemodes: libsmbsharemodes does neither depend on 
krb5 or ldap.
   via  9154f0b nsswitch: make libwbclient a public library again.
   via  3c9703f s3-waf: we need to globally -Ilib/replace
   via  a2f4a17 s3-waf: fix popt support.
  from  1ad8e52 lib/util/charset Add back setlocale(), but only when called 
from binaries

http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master


- Log -
commit 927792b21235bf8409ea04022b2912728f21d79e
Author: Günther Deschner g...@samba.org
Date:   Fri Feb 18 15:54:51 2011 +0100

s3-smbsharemodes: libsmbsharemodes does neither depend on krb5 or ldap.

Guenther

Autobuild-User: Günther Deschner g...@samba.org
Autobuild-Date: Fri Feb 18 16:46:35 CET 2011 on sn-devel-104

commit 9154f0b4510ec9e3c7916b5fd3f37c441bd8c490
Author: Günther Deschner g...@samba.org
Date:   Fri Feb 18 15:40:59 2011 +0100

nsswitch: make libwbclient a public library again.

Guenther

commit 3c9703f4853f353b67314d9d6aac3f8c572a6fe8
Author: Günther Deschner g...@samba.org
Date:   Fri Feb 18 15:39:28 2011 +0100

s3-waf: we need to globally -Ilib/replace

Guenther

commit a2f4a17b5e005afa1a8b15921e81c42cda6bcec0
Author: Günther Deschner g...@samba.org
Date:   Fri Feb 18 15:33:25 2011 +0100

s3-waf: fix popt support.

Guenther

---

Summary of changes:
 buildtools/wafsamba/samba3.py |3 +++
 nsswitch/libwbclient/wscript_build|2 +-
 source3/pkgconfig/smbsharemodes.pc.in |2 +-
 source3/wscript   |4 +++-
 4 files changed, 8 insertions(+), 3 deletions(-)


Changeset truncated at 500 lines:

diff --git a/buildtools/wafsamba/samba3.py b/buildtools/wafsamba/samba3.py
index 6759450..9344e55 100644
--- a/buildtools/wafsamba/samba3.py
+++ b/buildtools/wafsamba/samba3.py
@@ -72,6 +72,9 @@ def s3_fix_kwargs(bld, kwargs):
 if not bld.CONFIG_SET('USING_SYSTEM_TALLOC'):
 extra_includes += [ '../lib/talloc' ]
 
+if not bld.CONFIG_SET('USING_SYSTEM_POPT'):
+extra_includes += [ '../lib/popt' ]
+
 # s3 builds assume that they will have a bunch of extra include paths
 includes = []
 for d in extra_includes:
diff --git a/nsswitch/libwbclient/wscript_build 
b/nsswitch/libwbclient/wscript_build
index 896e17d..d925515 100644
--- a/nsswitch/libwbclient/wscript_build
+++ b/nsswitch/libwbclient/wscript_build
@@ -4,5 +4,5 @@ bld.SAMBA_LIBRARY('wbclient',
source='wbc_guid.c wbc_idmap.c wbclient.c wbc_pam.c wbc_pwd.c wbc_sid.c 
wbc_util.c',
deps='winbind-client',
public_headers='wbclient.h',
-   private_library=True
+   vnum='0'
)
diff --git a/source3/pkgconfig/smbsharemodes.pc.in 
b/source3/pkgconfig/smbsharemodes.pc.in
index dcb0d2e..1af7d4f 100644
--- a/source3/pkgconfig/smbsharemodes.pc.in
+++ b/source3/pkgconfig/smbsharemodes.pc.in
@@ -9,6 +9,6 @@ Version: 0
 URL: http://www.samba.org/
 #Libs: -L@libdir@ -lsmbsharemodes
 Libs: -lsmbsharemodes
-Libs.private: -lsmbsharemodes @KRB5_LIBS@ @LDAP_LIBS@ @LIBS@
+Libs.private: -lsmbsharemodes @LIBS@
 Cflags: -I@includedir@
 
diff --git a/source3/wscript b/source3/wscript
index 7c01e8f..9e5a8de 100644
--- a/source3/wscript
+++ b/source3/wscript
@@ -86,13 +86,15 @@ def configure(conf):
 conf.RECURSE('../libcli/smbreadline')
 conf.RECURSE('../lib/util')
 
-conf.ADD_EXTRA_INCLUDES('''#source3 #source3/include''')
+conf.ADD_EXTRA_INCLUDES('''#source3 #source3/include #lib/replace''')
 if not conf.env.USING_SYSTEM_TDB:
 conf.ADD_EXTRA_INCLUDES('#lib/tdb/include')
 if not conf.env.USING_SYSTEM_TEVENT:
 conf.ADD_EXTRA_INCLUDES('#lib/tevent')
 if not conf.env.USING_SYSTEM_TALLOC:
 conf.ADD_EXTRA_INCLUDES('#lib/talloc')
+if not conf.env.USING_SYSTEM_POPT:
+conf.ADD_EXTRA_INCLUDES('#lib/popt')
 
 conf.ADD_LDFLAGS(-Wl,--export-dynamic, testflags=True)
 


-- 
Samba Shared Repository


[SCM] Samba Shared Repository - branch master updated

2011-02-18 Thread Volker Lendecke
The branch, master has been updated
   via  d05aa90 s3:vfs:syncops add option to disable metasync per share
  from  927792b s3-smbsharemodes: libsmbsharemodes does neither depend on 
krb5 or ldap.

http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master


- Log -
commit d05aa90384082c348113021500ac15716d060ead
Author: Christian Ambach christian.amb...@de.ibm.com
Date:   Fri Feb 18 13:03:52 2011 +0100

s3:vfs:syncops add option to disable metasync per share

introduce an option to disable the metadata sync
in case the filesystem handles this correctly the sync can be
skipped, but synchronization of the data that was written can still
be configured (in opposition to the disable flag disabling all
sync operations)

Autobuild-User: Volker Lendecke vlen...@samba.org
Autobuild-Date: Fri Feb 18 17:31:59 CET 2011 on sn-devel-104

---

Summary of changes:
 source3/modules/vfs_syncops.c |   18 ++
 1 files changed, 14 insertions(+), 4 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source3/modules/vfs_syncops.c b/source3/modules/vfs_syncops.c
index 2b7c2a3..76072ab 100644
--- a/source3/modules/vfs_syncops.c
+++ b/source3/modules/vfs_syncops.c
@@ -2,6 +2,7 @@
  * ensure meta data operations are performed synchronously
  *
  * Copyright (C) Andrew Tridgell 2007
+ * Copyright (C) Christian Ambach, 2010-2011
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
@@ -37,13 +38,19 @@
  syncops:onclose = no
   that can be set either globally or per share.
 
-  you can also disable the module completely for a service with
+  On certain filesystems that only require the last data written to be
+  fsync()'ed, you can disable the metadata synchronization of this module with
+ syncops:onmeta = no
+  This option can be set either globally or per share.
+
+  you can also disable the module completely for a share with
  syncops:disable = true
 
  */
 
 struct syncops_config_data {
bool onclose;
+   bool onmeta;
bool disable;
 };
 
@@ -142,7 +149,7 @@ static int syncops_rename(vfs_handle_struct *handle,
return -1);
 
ret = SMB_VFS_NEXT_RENAME(handle, smb_fname_src, smb_fname_dst);
-   if (ret == 0  !config-disable) {
+   if (ret == 0  config-onmeta  !config-disable) {
syncops_two_names(smb_fname_src-base_name,
  smb_fname_dst-base_name);
}
@@ -158,7 +165,7 @@ static int syncops_rename(vfs_handle_struct *handle,
return -1); \
ret = SMB_VFS_NEXT_ ## op args; \
if (ret == 0 \
-!config-disable \
+config-onmeta  !config-disable  \
 fname) syncops_name(fname); \
return ret; \
 } while (0)
@@ -171,7 +178,7 @@ static int syncops_rename(vfs_handle_struct *handle,
return -1); \
ret = SMB_VFS_NEXT_ ## op args; \
if (ret == 0 \
-!config-disable \
+config-onmeta  !config-disable \
 fname) syncops_smb_fname(fname); \
return ret; \
 } while (0)
@@ -255,6 +262,9 @@ int syncops_connect(struct vfs_handle_struct *handle, const 
char *service,
config-onclose = lp_parm_bool(SNUM(handle-conn), syncops,
onclose, true);
 
+   config-onmeta = lp_parm_bool(SNUM(handle-conn), syncops,
+   onmeta, true);
+
config-disable = lp_parm_bool(SNUM(handle-conn), syncops,
disable, false);
 


-- 
Samba Shared Repository


[SCM] Samba Shared Repository - branch master updated

2011-02-18 Thread Jeremy Allison
The branch, master has been updated
   via  187f695 Fix alignment issues in SPOOLSS BUFFER marshalling. 
Guenther and Metze please check !
  from  d05aa90 s3:vfs:syncops add option to disable metasync per share

http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master


- Log -
commit 187f695469071d0550613e037b36170facb85460
Author: Jeremy Allison j...@samba.org
Date:   Fri Feb 18 09:01:46 2011 -0800

Fix alignment issues in SPOOLSS BUFFER marshalling.
Guenther and Metze please check !

Autobuild-User: Jeremy Allison j...@samba.org
Autobuild-Date: Fri Feb 18 18:49:55 CET 2011 on sn-devel-104

---

Summary of changes:
 pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm |7 +++
 1 files changed, 7 insertions(+), 0 deletions(-)


Changeset truncated at 500 lines:

diff --git a/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm 
b/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm
index 075ad85..eda583e 100644
--- a/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm
+++ b/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm
@@ -1281,12 +1281,19 @@ sub ParseStructPushPrimitives($)
 sub ParseStructPushDeferred()
 {
my ($self, $struct, $ndr, $varname, $env) = @_;
+
if (defined($struct-{PROPERTIES}{relative_base})) {
+   $self-pidl(NDR_CHECK(ndr_push_align($ndr, 
$struct-{ALIGN})););
+
# retrieve the current offset as base for relative pointers
# based on the toplevel struct/union

$self-pidl(NDR_CHECK(ndr_push_setup_relative_base_offset2($ndr, $varname)););
}
$self-ParseElementPush($_, $ndr, $env, 0, 1) foreach 
(@{$struct-{ELEMENTS}});
+
+   if (defined($struct-{PROPERTIES}{relative_base})) {
+   $self-pidl(NDR_CHECK(ndr_push_trailer_align($ndr, 
$struct-{ALIGN})););
+   }
 }
 
 #


-- 
Samba Shared Repository


[SCM] Samba Shared Repository - branch v3-6-test updated

2011-02-18 Thread Jeremy Allison
The branch, v3-6-test has been updated
   via  f6ac3bb Fix alignment issues in SPOOLSS BUFFER marshalling. 
Guenther and Metze please check ! (cherry picked from commit 
8b881e7b6f3b0089ea874b3decd49379b963eb63)
   via  b7acfce s3:vfs:syncops add option to disable metasync per share
  from  8c86c25 tevent: Fix a comment

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


- Log -
commit f6ac3bb3cf499b658774fe9317d91b7570d2fa32
Author: Jeremy Allison j...@samba.org
Date:   Fri Feb 18 09:01:46 2011 -0800

Fix alignment issues in SPOOLSS BUFFER marshalling.
Guenther and Metze please check !
(cherry picked from commit 8b881e7b6f3b0089ea874b3decd49379b963eb63)

commit b7acfce50b21389fd391c228a6eef7fcf91e
Author: Christian Ambach christian.amb...@de.ibm.com
Date:   Fri Feb 18 13:03:52 2011 +0100

s3:vfs:syncops add option to disable metasync per share

introduce an option to disable the metadata sync
in case the filesystem handles this correctly the sync can be
skipped, but synchronization of the data that was written can still
be configured (in opposition to the disable flag disabling all
sync operations)

Autobuild-User: Volker Lendecke vlen...@samba.org
Autobuild-Date: Fri Feb 18 17:31:59 CET 2011 on sn-devel-104
(cherry picked from commit d05aa90384082c348113021500ac15716d060ead)

---

Summary of changes:
 pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm |7 +++
 source3/modules/vfs_syncops.c|   18 ++
 2 files changed, 21 insertions(+), 4 deletions(-)


Changeset truncated at 500 lines:

diff --git a/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm 
b/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm
index 075ad85..eda583e 100644
--- a/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm
+++ b/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm
@@ -1281,12 +1281,19 @@ sub ParseStructPushPrimitives($)
 sub ParseStructPushDeferred()
 {
my ($self, $struct, $ndr, $varname, $env) = @_;
+
if (defined($struct-{PROPERTIES}{relative_base})) {
+   $self-pidl(NDR_CHECK(ndr_push_align($ndr, 
$struct-{ALIGN})););
+
# retrieve the current offset as base for relative pointers
# based on the toplevel struct/union

$self-pidl(NDR_CHECK(ndr_push_setup_relative_base_offset2($ndr, $varname)););
}
$self-ParseElementPush($_, $ndr, $env, 0, 1) foreach 
(@{$struct-{ELEMENTS}});
+
+   if (defined($struct-{PROPERTIES}{relative_base})) {
+   $self-pidl(NDR_CHECK(ndr_push_trailer_align($ndr, 
$struct-{ALIGN})););
+   }
 }
 
 #
diff --git a/source3/modules/vfs_syncops.c b/source3/modules/vfs_syncops.c
index 2b7c2a3..76072ab 100644
--- a/source3/modules/vfs_syncops.c
+++ b/source3/modules/vfs_syncops.c
@@ -2,6 +2,7 @@
  * ensure meta data operations are performed synchronously
  *
  * Copyright (C) Andrew Tridgell 2007
+ * Copyright (C) Christian Ambach, 2010-2011
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
@@ -37,13 +38,19 @@
  syncops:onclose = no
   that can be set either globally or per share.
 
-  you can also disable the module completely for a service with
+  On certain filesystems that only require the last data written to be
+  fsync()'ed, you can disable the metadata synchronization of this module with
+ syncops:onmeta = no
+  This option can be set either globally or per share.
+
+  you can also disable the module completely for a share with
  syncops:disable = true
 
  */
 
 struct syncops_config_data {
bool onclose;
+   bool onmeta;
bool disable;
 };
 
@@ -142,7 +149,7 @@ static int syncops_rename(vfs_handle_struct *handle,
return -1);
 
ret = SMB_VFS_NEXT_RENAME(handle, smb_fname_src, smb_fname_dst);
-   if (ret == 0  !config-disable) {
+   if (ret == 0  config-onmeta  !config-disable) {
syncops_two_names(smb_fname_src-base_name,
  smb_fname_dst-base_name);
}
@@ -158,7 +165,7 @@ static int syncops_rename(vfs_handle_struct *handle,
return -1); \
ret = SMB_VFS_NEXT_ ## op args; \
if (ret == 0 \
-!config-disable \
+config-onmeta  !config-disable  \
 fname) syncops_name(fname); \
return ret; \
 } while (0)
@@ -171,7 +178,7 @@ static int syncops_rename(vfs_handle_struct *handle,
return -1); \
ret = SMB_VFS_NEXT_ ## op args; \
if (ret == 0 \
-!config-disable \
+config-onmeta  !config-disable \
 fname) syncops_smb_fname(fname); \
 

[SCM] Samba Shared Repository - branch v3-6-test updated

2011-02-18 Thread Jeremy Allison
The branch, v3-6-test has been updated
   via  d4c0a2b s3: Fix a typed-punned warning
  from  f6ac3bb Fix alignment issues in SPOOLSS BUFFER marshalling. 
Guenther and Metze please check ! (cherry picked from commit 
8b881e7b6f3b0089ea874b3decd49379b963eb63)

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


- Log -
commit d4c0a2b9fdd05fe1e1ff0b57ee8a6b557bb857ee
Author: Volker Lendecke v...@samba.org
Date:   Mon Feb 7 14:43:09 2011 +0100

s3: Fix a typed-punned warning

Autobuild-User: Volker Lendecke vlen...@samba.org
Autobuild-Date: Mon Feb 14 11:46:50 CET 2011 on sn-devel-104
(cherry picked from commit e9f552925d0c007379d81af6ea9b0973011aed80)

---

Summary of changes:
 source3/nmbd/nmbd_packets.c |2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source3/nmbd/nmbd_packets.c b/source3/nmbd/nmbd_packets.c
index 48d10cc..5f900c4 100644
--- a/source3/nmbd/nmbd_packets.c
+++ b/source3/nmbd/nmbd_packets.c
@@ -497,7 +497,7 @@ struct response_record *queue_register_name( struct 
subnet_record *subrec,
return NULL;
 
in_addr_to_sockaddr_storage(ss, subrec-bcast_ip);
-   pss = iface_ip((struct sockaddr *)ss);
+   pss = iface_ip((struct sockaddr *)(void *)ss);
if (!pss || pss-ss_family != AF_INET) {
p-locked = False;
free_packet(p);


-- 
Samba Shared Repository


[SCM] Samba Shared Repository - branch v3-6-test updated

2011-02-18 Thread Jeremy Allison
The branch, v3-6-test has been updated
   via  776f83e vfs_smb_traffic_analyzer shall also transfer the clients IP 
address.
   via  3766fab s3: Fix a C++ warning
  from  d4c0a2b s3: Fix a typed-punned warning

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


- Log -
commit 776f83ee3d4d1e92b0e9f886d4d3e75c0fd77154
Author: Holger Hetterich hhet...@novell.com
Date:   Sun Feb 13 18:20:00 2011 +0100

vfs_smb_traffic_analyzer shall also transfer the clients IP address.

commit 3766fab194d8312e733ce462fbca3227aee4b17a
Author: Volker Lendecke v...@samba.org
Date:   Mon Feb 14 20:56:09 2011 +0100

s3: Fix a C++ warning

Autobuild-User: Volker Lendecke vlen...@samba.org
Autobuild-Date: Mon Feb 14 21:44:55 CET 2011 on sn-devel-104
(cherry picked from commit 64c63a3e1ca7206cb3bb11ff6c8c206bb9a00444)

---

Summary of changes:
 source3/libsmb/smb_share_modes.c   |2 +-
 source3/modules/vfs_smb_traffic_analyzer.c |9 ++---
 source3/modules/vfs_smb_traffic_analyzer.h |2 +-
 3 files changed, 8 insertions(+), 5 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source3/libsmb/smb_share_modes.c b/source3/libsmb/smb_share_modes.c
index e752f61..bf3250b 100644
--- a/source3/libsmb/smb_share_modes.c
+++ b/source3/libsmb/smb_share_modes.c
@@ -272,7 +272,7 @@ static uint32_t smb_name_hash(const char *sharepath, const 
char *filename, int *
uint32_t name_hash;
 
*err = 0;
-   fullpath = malloc(sharepath_size + filename_size + 2);
+   fullpath = (char *)malloc(sharepath_size + filename_size + 2);
if (fullpath == NULL) {
*err = 1;
return 0;
diff --git a/source3/modules/vfs_smb_traffic_analyzer.c 
b/source3/modules/vfs_smb_traffic_analyzer.c
index 8cde7f4..90acfcc 100644
--- a/source3/modules/vfs_smb_traffic_analyzer.c
+++ b/source3/modules/vfs_smb_traffic_analyzer.c
@@ -20,6 +20,7 @@
  */
 
 #include includes.h
+#include ../smbd/globals.h
 #include ../lib/crypto/crypto.h
 #include vfs_smb_traffic_analyzer.h
 #include ../libcli/security/security.h
@@ -313,6 +314,7 @@ static char *smb_traffic_analyzer_create_string( TALLOC_CTX 
*ctx,
 * 4.affected share
 * 5.domain
 * 6.timestamp
+* 7.IP Addresss of client
 */
 
/*
@@ -348,10 +350,9 @@ static char *smb_traffic_analyzer_create_string( 
TALLOC_CTX *ctx,
tm-tm_sec, \
(int)seconds);
len = strlen( timestr );
-
/* create the string of common data */
buf = talloc_asprintf(ctx,
-   %s%04u%s%04u%s%04u%s%04u%s%04u%s%04u%s,
+   %s%04u%s%04u%s%04u%s%04u%s%04u%s%04u%s%04u%s,
common_data_count_str,
(unsigned int) strlen(vfs_operation_str),
vfs_operation_str,
@@ -365,7 +366,9 @@ static char *smb_traffic_analyzer_create_string( TALLOC_CTX 
*ctx,
strlen(handle-conn-server_info-info3-base.domain.string),
handle-conn-server_info-info3-base.domain.string,
(unsigned int) strlen(timestr),
-   timestr);
+   timestr,
+   (unsigned int) strlen(handle-conn-sconn-client_id.addr),
+   handle-conn-sconn-client_id.addr);
 
talloc_free(common_data_count_str);
 
diff --git a/source3/modules/vfs_smb_traffic_analyzer.h 
b/source3/modules/vfs_smb_traffic_analyzer.h
index 3f47ea5..bfc0614 100644
--- a/source3/modules/vfs_smb_traffic_analyzer.h
+++ b/source3/modules/vfs_smb_traffic_analyzer.h
@@ -85,7 +85,7 @@
  * so that if the receiver is using an older version of the protocol
  * it knows which blocks it can ignore.
  */
-#define SMBTA_COMMON_DATA_COUNT 00016
+#define SMBTA_COMMON_DATA_COUNT 00017
 
 /*
  * VFS Functions identifier table. In protocol version 2, every vfs


-- 
Samba Shared Repository


[SCM] Samba Shared Repository - branch master updated

2011-02-18 Thread Jeremy Allison
The branch, master has been updated
   via  464c696 vfs_smb_traffic_analyzer shall also transfer the clients IP 
address.
  from  187f695 Fix alignment issues in SPOOLSS BUFFER marshalling. 
Guenther and Metze please check !

http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master


- Log -
commit 464c69609aa7e582f484c1d357b7c6d3eb2bcbe3
Author: Holger Hetterich hhet...@novell.com
Date:   Sun Feb 13 18:20:00 2011 +0100

vfs_smb_traffic_analyzer shall also transfer the clients IP address.

Autobuild-User: Jeremy Allison j...@samba.org
Autobuild-Date: Sat Feb 19 01:53:18 CET 2011 on sn-devel-104

---

Summary of changes:
 source3/modules/vfs_smb_traffic_analyzer.c |9 ++---
 source3/modules/vfs_smb_traffic_analyzer.h |2 +-
 2 files changed, 7 insertions(+), 4 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source3/modules/vfs_smb_traffic_analyzer.c 
b/source3/modules/vfs_smb_traffic_analyzer.c
index 6b41aff..cf90960 100644
--- a/source3/modules/vfs_smb_traffic_analyzer.c
+++ b/source3/modules/vfs_smb_traffic_analyzer.c
@@ -20,6 +20,7 @@
  */
 
 #include includes.h
+#include ../smbd/globals.h
 #include ../lib/crypto/crypto.h
 #include vfs_smb_traffic_analyzer.h
 #include ../libcli/security/security.h
@@ -313,6 +314,7 @@ static char *smb_traffic_analyzer_create_string( TALLOC_CTX 
*ctx,
 * 4.affected share
 * 5.domain
 * 6.timestamp
+* 7.IP Addresss of client
 */
 
/*
@@ -348,10 +350,9 @@ static char *smb_traffic_analyzer_create_string( 
TALLOC_CTX *ctx,
tm-tm_sec, \
(int)seconds);
len = strlen( timestr );
-
/* create the string of common data */
buf = talloc_asprintf(ctx,
-   %s%04u%s%04u%s%04u%s%04u%s%04u%s%04u%s,
+   %s%04u%s%04u%s%04u%s%04u%s%04u%s%04u%s%04u%s,
common_data_count_str,
(unsigned int) strlen(vfs_operation_str),
vfs_operation_str,
@@ -365,7 +366,9 @@ static char *smb_traffic_analyzer_create_string( TALLOC_CTX 
*ctx,
strlen(handle-conn-server_info-info3-base.domain.string),
handle-conn-server_info-info3-base.domain.string,
(unsigned int) strlen(timestr),
-   timestr);
+   timestr,
+   (unsigned int) strlen(handle-conn-sconn-client_id.addr),
+   handle-conn-sconn-client_id.addr);
 
talloc_free(common_data_count_str);
 
diff --git a/source3/modules/vfs_smb_traffic_analyzer.h 
b/source3/modules/vfs_smb_traffic_analyzer.h
index 3f47ea5..bfc0614 100644
--- a/source3/modules/vfs_smb_traffic_analyzer.h
+++ b/source3/modules/vfs_smb_traffic_analyzer.h
@@ -85,7 +85,7 @@
  * so that if the receiver is using an older version of the protocol
  * it knows which blocks it can ignore.
  */
-#define SMBTA_COMMON_DATA_COUNT 00016
+#define SMBTA_COMMON_DATA_COUNT 00017
 
 /*
  * VFS Functions identifier table. In protocol version 2, every vfs


-- 
Samba Shared Repository