samba.git
13 months agosmbd: Add some structure protection for durable reconnect
Volker Lendecke [Mon, 10 Sep 2018 12:53:37 +0000 (14:53 +0200)]
smbd: Add some structure protection for durable reconnect

We should consume all data, and the ndr_pull function fills in all
fields. Thus the ZERO_STRUCT(cookie) is not required.

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
13 months agowafsamba: Only use $DESTDIR in INSTALL_DIR() if it is set
Martin Schwenke [Thu, 13 Sep 2018 00:54:48 +0000 (10:54 +1000)]
wafsamba: Only use $DESTDIR in INSTALL_DIR() if it is set

Otherwise the leading '/' is stripped and directories are created
relative to the current directory.

This fixes a regression introduced in recent commit
26ea0f58daace4adef7c5bb17f19476083bf3b7b.

Reported-by: Ralph Böhme <slow@samba.org>
Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Alexander Bokovoy <ab@samba.org>
Autobuild-User(master): Martin Schwenke <martins@samba.org>
Autobuild-Date(master): Thu Sep 13 09:37:23 CEST 2018 on sn-devel-144

13 months agodbwrap_ctdb: return correct record count for a persistent db read-only traverse
Ralph Boehme [Mon, 10 Sep 2018 10:50:01 +0000 (12:50 +0200)]
dbwrap_ctdb: return correct record count for a persistent db read-only traverse

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Thu Sep 13 01:34:30 CEST 2018 on sn-devel-144

13 months agodbwrap_ctdb: increment record count in traverse_callback()
Ralph Boehme [Sun, 9 Sep 2018 16:51:43 +0000 (18:51 +0200)]
dbwrap_ctdb: increment record count in traverse_callback()

state->count wasn't incremented and is returned at the end of a
dbwrap_traverse().

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
13 months agodbwrap_ctdb: use struct initializer in db_ctdb_traverse()
Ralph Boehme [Sun, 9 Sep 2018 16:50:14 +0000 (18:50 +0200)]
dbwrap_ctdb: use struct initializer in db_ctdb_traverse()

This ensures all struct members are implicitly initialized.

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
13 months agodbwrap_ctdb: use struct initializer in db_ctdb_traverse_read()
Ralph Boehme [Sun, 9 Sep 2018 16:48:13 +0000 (18:48 +0200)]
dbwrap_ctdb: use struct initializer in db_ctdb_traverse_read()

This ensures all struct members are implicitly initialized.

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
13 months agodbwrap_ctdb: README.Coding fixes in traverse_callback()
Ralph Boehme [Sun, 9 Sep 2018 16:35:26 +0000 (18:35 +0200)]
dbwrap_ctdb: README.Coding fixes in traverse_callback()

NULL initialize pointers, check function return values, explicit
variable check against NULL.

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
13 months agodbwrap_ctdb: simplify if condition
Ralph Boehme [Tue, 4 Sep 2018 10:47:42 +0000 (12:47 +0200)]
dbwrap_ctdb: simplify if condition

This just moves the talloc_memdup() out of the if condition as per
README.Coding.

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
13 months agodbwrap_ctdb: add error checking to ctdbd_dbpath()
Ralph Boehme [Sun, 4 Mar 2018 22:39:05 +0000 (23:39 +0100)]
dbwrap_ctdb: add error checking to ctdbd_dbpath()

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
13 months agodbwrap_tdb: use struct initializer
Ralph Boehme [Sat, 18 Aug 2018 06:35:27 +0000 (08:35 +0200)]
dbwrap_tdb: use struct initializer

This ensures all struct members are implicitly initialized.

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
13 months agodbwrap_tdb: move a function call out of an if condition
Ralph Boehme [Sat, 18 Aug 2018 07:12:21 +0000 (09:12 +0200)]
dbwrap_tdb: move a function call out of an if condition

At least for me this improves readability somewhat. No change in
behaviour.

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
13 months agodbwrap: early return, removes an indentation level
Ralph Boehme [Sat, 18 Nov 2017 11:13:15 +0000 (12:13 +0100)]
dbwrap: early return, removes an indentation level

No change in behaviour.

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
13 months agodbwrap: move sockname variable and call to lp_ctdbd_socket into context
Ralph Boehme [Sat, 18 Nov 2017 07:56:09 +0000 (08:56 +0100)]
dbwrap: move sockname variable and call to lp_ctdbd_socket into context

sockname is only needed in a cluster.

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
13 months agoctdb-doc: Remove PIDFILE option from ctdbd_wrapper man page
Ralph Wuerthner [Tue, 11 Sep 2018 08:00:52 +0000 (10:00 +0200)]
ctdb-doc: Remove PIDFILE option from ctdbd_wrapper man page

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13610

Signed-off-by: Ralph Wuerthner <ralph.wuerthner@de.ibm.com>
Reviewed-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Ralph Böhme <slow@samba.org>
Autobuild-User(master): Martin Schwenke <martins@samba.org>
Autobuild-Date(master): Wed Sep 12 21:50:57 CEST 2018 on sn-devel-144

13 months agosamba_dnsupdate: honor 'dns zone scavenging' option, only update if needed
Björn Baumbach [Wed, 5 Sep 2018 14:54:01 +0000 (16:54 +0200)]
samba_dnsupdate: honor 'dns zone scavenging' option, only update if needed

Since scavenging is implemented the samba_dnsupdate command always updates all
dns records required by the dc. This is not needed if dns zone scavenging
is not enabled.

This avoids the repeating TSIG error messages:

 # samba_dnsupdate --option='dns zone scavenging = yes' 2>&1 | uniq -c
     29 ; TSIG error with server: tsig verify failure
      1 Failed update of 29 entries
 # echo ${PIPESTATUS[0]}
 29

 # samba_dnsupdate --option='dns zone scavenging = no' 2>&1 | uniq -c
 # echo ${PIPESTATUS[0]}
 0

Note that this results in about 60 lines in the log file,
which triggered every 10 minutes ("dnsupdate:name interval=600" is the default).

This restores the behavior before 8ef42d4dab4dfaf5ad225b33f7748914f14dcd8c,
if "dns zone scavenging" is not switched on (which is still the default).

Avoiding the message from happening at all is subject for more debugging,
most likely they are caused by bugs in 'nsupdate -g' (from the bind package).

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13605

Pair-programmed-with: Stefan Metzmacher <metze@samba.org>

Signed-off-by: Björn Baumbach <bb@sernet.de>
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Autobuild-User(master): Björn Baumbach <bb@sernet.de>
Autobuild-Date(master): Wed Sep 12 18:03:10 CEST 2018 on sn-devel-144

13 months agoctdb-build: Fix version handling when building tarball
Martin Schwenke [Sat, 8 Sep 2018 22:11:33 +0000 (08:11 +1000)]
ctdb-build: Fix version handling when building tarball

Split get_version() into 2 functions, so that .distversion file can be
created.

Pair-programmed-with: Amitay Isaacs <amitay@gmail.com>
Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Autobuild-User(master): Amitay Isaacs <amitay@samba.org>
Autobuild-Date(master): Wed Sep 12 05:50:46 CEST 2018 on sn-devel-144

13 months agosmbd:vfs: fix mis-spellings of hierarchy in comments
Michael Adam [Mon, 20 Aug 2018 10:04:20 +0000 (12:04 +0200)]
smbd:vfs: fix mis-spellings of hierarchy in comments

Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Wed Sep 12 02:05:47 CEST 2018 on sn-devel-144

13 months agos3: smbd: Ensure dirpath is set to ".", not "\0" so it is always a valid path.
Jeremy Allison [Wed, 22 Aug 2018 20:37:04 +0000 (13:37 -0700)]
s3: smbd: Ensure dirpath is set to ".", not "\0" so it is always a valid path.

Cleanup of the internals of unix_convert().

Ensure check_parent_exists() returns this in the non-optimization
case. Ensure unix_convert() initializes dirpath to ".".

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
13 months agos3: smbd: Restructure check_parent_exists() to ensure all non-optimization returns...
Jeremy Allison [Wed, 22 Aug 2018 16:15:12 +0000 (09:15 -0700)]
s3: smbd: Restructure check_parent_exists() to ensure all non-optimization returns go to one place.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
13 months agos3: smbd: Initialization cleanup.
Jeremy Allison [Wed, 22 Aug 2018 16:09:27 +0000 (09:09 -0700)]
s3: smbd: Initialization cleanup.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
13 months agos3:libsmbclient: Fix a typo
Andreas Schneider [Tue, 11 Sep 2018 12:56:54 +0000 (14:56 +0200)]
s3:libsmbclient: Fix a typo

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Tue Sep 11 21:43:28 CEST 2018 on sn-devel-144

13 months agos4: torture: Fix "flakey" notify test on slow cloud filesystems.
Jeremy Allison [Mon, 10 Sep 2018 22:35:03 +0000 (15:35 -0700)]
s4: torture: Fix "flakey" notify test on slow cloud filesystems.

Ensure we keep asking for change notifies until we get them all
(or the request times out).

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
13 months agosmbd: Use has_other_nonposix_opens in smb_posix_unlink
Volker Lendecke [Sat, 8 Sep 2018 16:05:57 +0000 (18:05 +0200)]
smbd: Use has_other_nonposix_opens in smb_posix_unlink

Almost the same code as in close.c. has_other_nonposix_opens() is a bit
more general, but the purpose is the same.

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
13 months agosmbd: Factor out "has_other_nonposix_opens"
Volker Lendecke [Sat, 8 Sep 2018 14:58:36 +0000 (16:58 +0200)]
smbd: Factor out "has_other_nonposix_opens"

This is exactly the same in both file and directory cases

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
13 months agosmbd: Remove an unneeded #include
Volker Lendecke [Sat, 8 Sep 2018 11:50:46 +0000 (13:50 +0200)]
smbd: Remove an unneeded #include

ndr_open_files already includes open_files.h

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
13 months agosmbd: Simplify close_directory()
Volker Lendecke [Sat, 8 Sep 2018 11:44:30 +0000 (13:44 +0200)]
smbd: Simplify close_directory()

Same patch as in 8541829a9ab20c7fa8c

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
13 months agosmbd: Remove an unneeded #include
Volker Lendecke [Sat, 8 Sep 2018 10:45:54 +0000 (12:45 +0200)]
smbd: Remove an unneeded #include

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
13 months agowafsamba: Drop unused, broken install_dir()
Martin Schwenke [Tue, 11 Sep 2018 04:35:38 +0000 (14:35 +1000)]
wafsamba: Drop unused, broken install_dir()

This is broken because it doesn't respect $DESTDIR.

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Alexander Bokovoy <ab@samba.org>
Autobuild-User(master): Alexander Bokovoy <ab@samba.org>
Autobuild-Date(master): Tue Sep 11 10:00:05 CEST 2018 on sn-devel-144

13 months agowafsamba: Have INSTALL_DIR() log directory creation
Martin Schwenke [Tue, 11 Sep 2018 04:35:02 +0000 (14:35 +1000)]
wafsamba: Have INSTALL_DIR() log directory creation

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Alexander Bokovoy <ab@samba.org>
13 months agowafsamba: Make INSTALL_DIR() respect $DESTDIR
Martin Schwenke [Mon, 10 Sep 2018 00:35:24 +0000 (10:35 +1000)]
wafsamba: Make INSTALL_DIR() respect $DESTDIR

INSTALL_DIR() currently ignores $DESTDIR and just installs directories
into the final destination.

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Alexander Bokovoy <ab@samba.org>
13 months agoctdb-build: Use wafsamba's INSTALL_DIR()
Martin Schwenke [Sun, 9 Sep 2018 10:34:31 +0000 (20:34 +1000)]
ctdb-build: Use wafsamba's INSTALL_DIR()

install_dir() doesn't work (doesn't respect $DESTDIR) and is only
available for backward compatibilty.

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Alexander Bokovoy <ab@samba.org>
13 months agowafsamba: remove tru64cc.py as it's not compatible with waf 2
Stefan Metzmacher [Fri, 7 Sep 2018 14:40:44 +0000 (16:40 +0200)]
wafsamba: remove tru64cc.py as it's not compatible with waf 2

third_party/waf/waflib/Tools/compiler_c.py proposed
gcc for osf1V/Tru64.

If there's more needed on Tru64 someone with a Tru64 box needs to
provide a waf 2 compatible fix.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Mon Sep 10 22:49:31 CEST 2018 on sn-devel-144

13 months agowafsamba: remove hpuxcc.py as it's not compatible with waf 2
Stefan Metzmacher [Fri, 7 Sep 2018 14:40:44 +0000 (16:40 +0200)]
wafsamba: remove hpuxcc.py as it's not compatible with waf 2

third_party/waf/waflib/Tools/compiler_c.py proposed
gcc for HPUX.

If there's more needed on HPUX someone with a HPUX box needs to
provide a waf 2 compatible fix.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
13 months agowafsamba: remove irixcc.py as we don't support IRIX any more
Stefan Metzmacher [Fri, 7 Sep 2018 14:32:28 +0000 (16:32 +0200)]
wafsamba: remove irixcc.py as we don't support IRIX any more

There's still a irixcc.py in waf itself.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
13 months agowafsamba: fix generic_cc.py to work with waf 2
Stefan Metzmacher [Fri, 7 Sep 2018 14:27:58 +0000 (16:27 +0200)]
wafsamba: fix generic_cc.py to work with waf 2

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
13 months agobuildtools/wafsamba: undefine a define for a failed test unless asked to keep it
Alexander Bokovoy [Fri, 7 Sep 2018 14:34:48 +0000 (14:34 +0000)]
buildtools/wafsamba: undefine a define for a failed test unless asked to keep it

If conf.CHECK_CODE() is called without `always=True` and the test has
failed, undefine the define already set to '0' by conf.check_code().

This restores expectations that undefined symbols are not considered to
be set by CONFIG_SET() method.

Signed-off-by: Alexander Bokovoy <ab@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
13 months agoRevert "wafsamba/samba_autoconf: when setting undefined result, use empty tuple"
Stefan Metzmacher [Mon, 10 Sep 2018 08:22:16 +0000 (10:22 +0200)]
Revert "wafsamba/samba_autoconf: when setting undefined result, use empty tuple"

This reverts commit 95ba6b97441b75f28aef5ec1ee5a9442683f3763.

There was already a better fix under discusion.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
13 months agoRevert "lib/replace: force to unset defines if check has failed"
Stefan Metzmacher [Mon, 10 Sep 2018 08:22:13 +0000 (10:22 +0200)]
Revert "lib/replace: force to unset defines if check has failed"

This reverts commit 8ec7eb0c0129518557d1f446191860a62ef3ff79.

There was already a better fix under discusion.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
13 months agoselftext: Mark py3 visualize test as flapping
Douglas Bagnall [Sun, 9 Sep 2018 22:08:41 +0000 (10:08 +1200)]
selftext: Mark py3 visualize test as flapping

Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
Reviewed-by: Andreas Schneider <asn@samba.org>
Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Mon Sep 10 16:51:09 CEST 2018 on sn-devel-144

13 months agos4: torture: Ensure raw notify tests use different directories.
Jeremy Allison [Fri, 7 Sep 2018 22:14:37 +0000 (15:14 -0700)]
s4: torture: Ensure raw notify tests use different directories.

Should help track down flapping tests.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Sat Sep  8 11:37:44 CEST 2018 on sn-devel-144

13 months agolib/replace: force to unset defines if check has failed
Alexander Bokovoy [Thu, 6 Sep 2018 09:07:28 +0000 (09:07 +0000)]
lib/replace: force to unset defines if check has failed

For HAVE_WORKING_STRPTIME and HAVE_INCOHERENT_MMAP we always want to
have their defines unset as the code is using '#ifdef' rather than just
'#if'. Setting them to 0 means #ifdef will succeed due to a difference
how '#ifdef' and '#if' are working.

Signed-off-by: Alexander Bokovoy <ab@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
13 months agowafsamba/samba_autoconf: when setting undefined result, use empty tuple
Alexander Bokovoy [Thu, 6 Sep 2018 07:51:00 +0000 (07:51 +0000)]
wafsamba/samba_autoconf: when setting undefined result, use empty tuple

A difference between waf 1.x and 2.x is that we gained 0 as an undefined
variable in the cache file. This does not allow to differentiate unset
and set to 0 defines.

Force to use empty tuple () to signify unset defines.

Signed-off-by: Alexander Bokovoy <ab@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
13 months agospoolss-iremotewinspool-tests: Use more recent client OS version
Justin Stephenson [Fri, 31 Aug 2018 19:28:36 +0000 (15:28 -0400)]
spoolss-iremotewinspool-tests: Use more recent client OS version

Set torture test client info build, major, and minor
version numbers to Windows 7 and Windows Server 2008 R2 values

 buildnum: 7007
 major: 6
 minor: 1

Build number taken from
 [MS-RPRN] <168> Section 2.2.3.10.1

Major/Minor numbers taken from
 https://docs.microsoft.com/en-us/windows/desktop/sysinfo/operating-system-version

Signed-off-by: Justin Stephenson <jstephen@redhat.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Sat Sep  8 04:35:56 CEST 2018 on sn-devel-144

13 months agoiremotewinspool-tests: Add client os build number validation test
Justin Stephenson [Wed, 22 Aug 2018 17:23:18 +0000 (13:23 -0400)]
iremotewinspool-tests: Add client os build number validation test

Add test validating the AsyncOpenPrinter result based on the provided
client info build number

Signed-off-by: Justin Stephenson <jstephen@redhat.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
13 months agoiremotewinspool-tests: Allow modification of OS client version information
Justin Stephenson [Wed, 15 Aug 2018 15:10:21 +0000 (11:10 -0400)]
iremotewinspool-tests: Allow modification of OS client version information

Add test_get_client_info() function to set and, or modify the client OS
version values advertised in the iremotewinspool torture tests.

The OS build numbers are used from the table in:

  [MS-RPRN] <168> Section 2.2.3.10.1

Signed-off-by: Justin Stephenson <jstephen@redhat.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
13 months agos3-rpcclient: Use spoolss_init_spoolss_UserLevel1 in winspool cmds
Günther Deschner [Fri, 31 Aug 2018 16:22:04 +0000 (18:22 +0200)]
s3-rpcclient: Use spoolss_init_spoolss_UserLevel1 in winspool cmds

Use spoolss initialization function to set client version information for
iremotewinspool printer operations

Signed-off-by: Guenther Deschner <gd@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
13 months agos3-rpc_client: Advertise Windows 7 client info
Justin Stephenson [Fri, 31 Aug 2018 17:28:58 +0000 (13:28 -0400)]
s3-rpc_client: Advertise Windows 7 client info

Client printing operations currently fail against Windows
Server 2016 with Access Denied if a client os build number
lower than 6000 is advertised. Increase the default build number,
major, and minor versions to values associated with client
OS versoins Windows 7 and Windows Server 2008 R2.

The build number value specifically needs to be increased to
allow these operations to succeed.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13597

Signed-off-by: Justin Stephenson <jstephen@redhat.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
13 months agos3-spoolss: Make spoolss client os_major,os_minor and os_build configurable.
Günther Deschner [Fri, 31 Aug 2018 15:36:19 +0000 (17:36 +0200)]
s3-spoolss: Make spoolss client os_major,os_minor and os_build configurable.

Similar to spoolss server options, make the client advertised OS version
values configurable to allow overriding the defaults provided to the print server.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13597

Signed-off-by: Guenther Deschner <gd@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
13 months agowafsamba: Fix 'make -j<jobs>'
Andreas Schneider [Thu, 6 Sep 2018 10:40:10 +0000 (12:40 +0200)]
wafsamba: Fix 'make -j<jobs>'

Currently only 'make -j' enables parallel builds and e.g. 'make -j4'
results in no parallel compile jobs at all.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13606

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Alexander Bokovoy <ab@samba.org>
Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Fri Sep  7 20:24:46 CEST 2018 on sn-devel-144

13 months agoctdb-tests: Fix CTDB -O3 --picky-developer build on CentOS 7
Martin Schwenke [Thu, 6 Sep 2018 06:06:40 +0000 (16:06 +1000)]
ctdb-tests: Fix CTDB -O3 --picky-developer build on CentOS 7

gcc 4.8.5 complains:

[319/381] Compiling ctdb/tests/src/system_socket_test.c
../tests/src/system_socket_test.c: In function ‘test_tcp’:
../tests/src/system_socket_test.c:196:20: error: ‘rst_out’ may be used uninitialized in this function [-Werror=maybe-uninitialized]
  assert((rst != 0) == (rst_out != 0));
                    ^
cc1: all warnings being treated as errors

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Andreas Schneider <asn@samba.org>
13 months agodbwrap: Remove a pointless "return;"
Volker Lendecke [Fri, 31 Aug 2018 04:09:48 +0000 (06:09 +0200)]
dbwrap: Remove a pointless "return;"

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
13 months agovfs_fruit: fix an uninitialized variable error
Volker Lendecke [Wed, 5 Sep 2018 09:31:10 +0000 (11:31 +0200)]
vfs_fruit: fix an uninitialized variable error

clang does not recognize "smb_panic" as an "exit()" equivalent

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
13 months agosmbd: Simplify logic in remove_stale_share_mode_entries
Volker Lendecke [Mon, 30 Jul 2018 11:21:26 +0000 (13:21 +0200)]
smbd: Simplify logic in remove_stale_share_mode_entries

To me, an early "continue" is easier to follow than a "else".

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
13 months agosmbd: Simplify share_mode_stale_pid
Volker Lendecke [Mon, 30 Jul 2018 11:03:17 +0000 (13:03 +0200)]
smbd: Simplify share_mode_stale_pid

This loop does not need to count valid share modes. A single valid one
is sufficient for keeping the delete token around

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
13 months agosmbd: Simplify lease_match() a bit
Volker Lendecke [Fri, 27 Jul 2018 12:16:20 +0000 (14:16 +0200)]
smbd: Simplify lease_match() a bit

This has been implicitly initialized to 0 with the explicit struct
initializer above.

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
13 months agosmbd: Simplify logic in fsp_lease_update
Volker Lendecke [Thu, 26 Jul 2018 13:46:18 +0000 (15:46 +0200)]
smbd: Simplify logic in fsp_lease_update

One if-condition is better than two

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
13 months agosmbd: Simplify logic in smb2_lease_break_send
Volker Lendecke [Thu, 26 Jul 2018 12:52:55 +0000 (14:52 +0200)]
smbd: Simplify logic in smb2_lease_break_send

If/else if chains are hard to follow to me. Simplify the code by using
early returns.

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
13 months agosmbd: Factor out file_has_read_oplocks()
Volker Lendecke [Thu, 26 Jul 2018 10:35:30 +0000 (12:35 +0200)]
smbd: Factor out file_has_read_oplocks()

Why? This makes it clearer to me that we're not interested in the actual
number of read oplocks. We only want to know if there are any read
oplocks at all.

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
13 months agos3:lib: Rename server_contexts to global_contexts
Christof Schmitt [Tue, 21 Aug 2018 20:08:42 +0000 (13:08 -0700)]
s3:lib: Rename server_contexts to global_contexts

Signed-off-by: Christof Schmitt <cs@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
13 months agos3:lib/server_contexts: Rename variables
Christof Schmitt [Tue, 21 Aug 2018 18:18:08 +0000 (11:18 -0700)]
s3:lib/server_contexts: Rename variables

Signed-off-by: Christof Schmitt <cs@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
13 months agos3: Rename server_messaging_context() to global_messaging_context()
Christof Schmitt [Tue, 21 Aug 2018 18:09:16 +0000 (11:09 -0700)]
s3: Rename server_messaging_context() to global_messaging_context()

This reflects that the messaging context is also used outside of the
server processes.

The command used for the rename:
find . -name '*.[hc]' -print0 | xargs -0 sed -i 's/server_messaging_context/global_messaging_context/'

Signed-off-by: Christof Schmitt <cs@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
13 months agos3: Rename server_event_context() to global_event_context()
Christof Schmitt [Tue, 21 Aug 2018 18:06:16 +0000 (11:06 -0700)]
s3: Rename server_event_context() to global_event_context()

This reflects that the event context is also used outside of the server
processes.

The command used for the rename:
find . -name '*.[hc]' -print0 | xargs -0 sed -i 's/server_event_context/global_event_context/'

Signed-off-by: Christof Schmitt <cs@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
13 months agoexamples: Fix the smb2mount build
Volker Lendecke [Fri, 7 Sep 2018 05:27:46 +0000 (07:27 +0200)]
examples: Fix the smb2mount build

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13465

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
13 months agos3:smbget: Use cmdline_messaging_context
Christof Schmitt [Tue, 21 Aug 2018 23:11:02 +0000 (16:11 -0700)]
s3:smbget: Use cmdline_messaging_context

Initialize the messaging context through cmdline_messaging_context to
allow access to config in clustered Samba.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13465

Signed-off-by: Christof Schmitt <cs@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
13 months agos3:smbcontrol: Use cmdline_messaging_context
Christof Schmitt [Tue, 21 Aug 2018 19:35:11 +0000 (12:35 -0700)]
s3:smbcontrol: Use cmdline_messaging_context

Initialize the messaging context through cmdline_messaging_context to
allow access to config in clustered Samba.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13465

Signed-off-by: Christof Schmitt <cs@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
13 months agos3:dbwrap_tool: Use cmdline_messaging_context
Christof Schmitt [Tue, 21 Aug 2018 19:34:34 +0000 (12:34 -0700)]
s3:dbwrap_tool: Use cmdline_messaging_context

Initialize the messaging context through cmdline_messaging_context to
allow access to config in clustered Samba.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13465

Signed-off-by: Christof Schmitt <cs@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
13 months agos3:eventlogadm: Use cmdline_messaging_context
Christof Schmitt [Mon, 20 Aug 2018 23:21:51 +0000 (16:21 -0700)]
s3:eventlogadm: Use cmdline_messaging_context

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13465

Signed-off-by: Christof Schmitt <cs@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
13 months agos3: ntlm_auth: Use cmdline_messaging_context
Christof Schmitt [Mon, 20 Aug 2018 23:18:20 +0000 (16:18 -0700)]
s3: ntlm_auth: Use cmdline_messaging_context

Call cmdline_messaging_context to initialize the messaging context
before accessing clustered Samba config.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13465

Signed-off-by: Christof Schmitt <cs@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
13 months agos3:sharesec: Use cmdline_messaging_context
Christof Schmitt [Mon, 20 Aug 2018 23:15:02 +0000 (16:15 -0700)]
s3:sharesec: Use cmdline_messaging_context

Call cmdline_messasging_context to initialize messaging context before
accessing clustered Samba config.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13465

Signed-off-by: Christof Schmitt <cs@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
13 months agos3:testparm: Use cmdline_messaging_context
Christof Schmitt [Mon, 20 Aug 2018 23:11:11 +0000 (16:11 -0700)]
s3:testparm: Use cmdline_messaging_context

Call cmdline_messaging_context to initialize a messaging config before
accessing clustered Samba config.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13465

Signed-off-by: Christof Schmitt <cs@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
13 months agos3:pdbedit: Use cmdline_messaging_context
Christof Schmitt [Mon, 20 Aug 2018 23:08:21 +0000 (16:08 -0700)]
s3:pdbedit: Use cmdline_messaging_context

Initialize the messaging context through cmdline_messaging_context to
allow access to config in clustered Samba.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13465

Signed-off-by: Christof Schmitt <cs@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
13 months agos3:messaging: remove unused messaging_init_client()
Ralph Boehme [Tue, 10 Jul 2018 14:29:46 +0000 (16:29 +0200)]
s3:messaging: remove unused messaging_init_client()

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13465

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Christof Schmitt <cs@samba.org>
13 months agos3:net: Use cmdline_messaging_context
Christof Schmitt [Mon, 20 Aug 2018 23:01:00 +0000 (16:01 -0700)]
s3:net: Use cmdline_messaging_context

Use cmdline_messaging_context with its error checking instead of open
coding the same steps.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13465

Signed-off-by: Christof Schmitt <cs@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
13 months agorpcclient: Use cmdline_messaging_context
Christof Schmitt [Mon, 20 Aug 2018 22:54:11 +0000 (15:54 -0700)]
rpcclient: Use cmdline_messaging_context

Use cmdline_messaging_context with its error checking instead of open
coding the same steps.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13465

Signed-off-by: Christof Schmitt <cs@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
13 months agos3:smbstatus: Use cmdline_messaging_context
Christof Schmitt [Mon, 20 Aug 2018 22:46:27 +0000 (15:46 -0700)]
s3:smbstatus: Use cmdline_messaging_context

Use cmdline_messaging_context to initialize a messaging context instead
of open coding the same steps.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13465

Signed-off-by: Christof Schmitt <cs@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
13 months agos3:smbpasswd: Use cmdline_messaging_context
Christof Schmitt [Mon, 20 Aug 2018 22:38:33 +0000 (15:38 -0700)]
s3:smbpasswd: Use cmdline_messaging_context

smbpasswd does not use POPT_CREDENTIALS. Call cmdline_messaging_context
to initialize a messaging_context with proper error checking before
calling lp_load_global.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13465

Signed-off-by: Christof Schmitt <cs@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
13 months agotest:doc: Skip 'clustering=yes'
Christof Schmitt [Tue, 21 Aug 2018 21:58:01 +0000 (14:58 -0700)]
test:doc: Skip 'clustering=yes'

As testparm will error out when running clustering=yes as non-root, skip
this step to avoid a test failure.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13465

Signed-off-by: Christof Schmitt <cs@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
13 months agos3:popt_common: use cmdline_messaging_context() in popt_common_credentials_callback()
Ralph Boehme [Tue, 10 Jul 2018 13:26:40 +0000 (15:26 +0200)]
s3:popt_common: use cmdline_messaging_context() in popt_common_credentials_callback()

This adds a call to cmdline_messaging_context() to the popt
popt_common_credentials_callback() hook and ensures that any client tool
that uses POPT_COMMON_CREDENTIALS gets an implicit messaging context,
ensuring it doesn't crash in the subsequent lp_load_client() with
include=registry in a cluster.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13465

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Christof Schmitt <cs@samba.org>
13 months agoselftest: pass configfile to pdbedit
Ralph Boehme [Tue, 10 Jul 2018 08:38:10 +0000 (10:38 +0200)]
selftest: pass configfile to pdbedit

This is needed otherwise pdbedit fails to initialize messaging in
autobuild.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13465

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Christof Schmitt <cs@samba.org>
13 months agos3:loadparm: reinit_globals in lp_load_with_registry_shares()
Ralph Boehme [Tue, 10 Jul 2018 06:11:31 +0000 (08:11 +0200)]
s3:loadparm: reinit_globals in lp_load_with_registry_shares()

This was set to false in 0e0d77519c27038b30fec92d542198e97be767d9 based
on the assumption that callers would have no need to call
lp_load_initial_only() with a later call to lp_load_something().

This is not quite correct, since for accessing registry config on a
cluster with include=registry, we need messaging up and running which
*itself* requires loadparm to be initialized to get the statedir,
lockdir asf. directories.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13465

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Christof Schmitt <cs@samba.org>
13 months agos3:lib: Introduce cmdline context wrapper
Christof Schmitt [Mon, 20 Aug 2018 21:44:28 +0000 (14:44 -0700)]
s3:lib: Introduce cmdline context wrapper

Command line tools need acccess to the same messaging context provided
by server_messaging_context, as common code for db_open uses that
context. We want to have additional checking for command line tools
without having that code part of the servers. Introduce a wrapper
library to use for command line tools with the additional checks, that
then acquires the server_messaging_context.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13465

Signed-off-by: Christof Schmitt <cs@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
13 months agos3:lib: Move popt_common_credentials to separate file
Christof Schmitt [Mon, 13 Aug 2018 22:39:08 +0000 (15:39 -0700)]
s3:lib: Move popt_common_credentials to separate file

This is only used by command line utilities and has additional
dependencies. Move to a separate file to contain the dependencies to the
command line tools.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13465

Signed-off-by: Christof Schmitt <cs@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
13 months agos3/lib:popt_common: Move setup_logging to common callback
Christof Schmitt [Mon, 13 Aug 2018 22:07:20 +0000 (15:07 -0700)]
s3/lib:popt_common: Move setup_logging to common callback

The flag is set in the common callback, so be consistent

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13465

Signed-off-by: Christof Schmitt <cs@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
13 months agos3:lib/server_contexts: make server_event_ctx and server_msg_ctx static
Ralph Boehme [Mon, 9 Jul 2018 15:11:57 +0000 (17:11 +0200)]
s3:lib/server_contexts: make server_event_ctx and server_msg_ctx static

server_event_ctx and server_msg_ctx static shouldn't be accessible from
outside this compilation unit.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13465

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Christof Schmitt <cs@samba.org>
13 months agowafsamba/samba_waf18: redefine flex function
Alexander Bokovoy [Thu, 6 Sep 2018 06:36:18 +0000 (09:36 +0300)]
wafsamba/samba_waf18: redefine flex function

There is a bug in waf: flex routine adjusts its inputs against
the task's current working directory but assumes it is being called from
within the build variant directory.

For Samba this means we adjust one level up than the actual work
directory we use to run (bin/ vs bin/default) and flex doesn't find the
source files.

Fix the issue by creating a local override of flex definition that
utilizes the same workd directory for both path adjustment and running
the flex itself.

Signed-off-by: Alexander Bokovoy <ab@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Fri Sep  7 15:45:36 CEST 2018 on sn-devel-144

13 months agolib/replace/wscript: fix detection of a fallthrough attribute for clang
Alexander Bokovoy [Thu, 6 Sep 2018 09:50:58 +0000 (09:50 +0000)]
lib/replace/wscript: fix detection of a fallthrough attribute for clang

clang issues a warning but otherwise allows our test to be compiled and
linked. We consider this case a successful pass for a fallthrough
attribute detection while it is an error.

Turn missing declaration warning into an error so that we actually do
not define fallthrough attribute support in case it doesn't really work.

Fixes FreeBSD 11.2 with clang.

Signed-off-by: Alexander Bokovoy <ab@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
13 months agowafsamba/samba_autoconf: when setting undefined result, use empty tuple
Alexander Bokovoy [Thu, 6 Sep 2018 07:51:00 +0000 (07:51 +0000)]
wafsamba/samba_autoconf: when setting undefined result, use empty tuple

A difference between waf 1.x and 2.x is that we gained 0 as an undefined
variable in the cache file. This does not allow to differentiate unset
and set to 0 defines.

Force to use empty tuple () to signify unset defines.

Also, fix handling of extra cflags in case of 'strict=True': if
extra_cflags were not defined, we'd append None to the cflags list and
it confuses conf.check() later. 'None' is added to the command line of a
tool executed by the conf.check() which, depending on a tool, may be
treated as an error and cause wrong test result.

Signed-off-by: Alexander Bokovoy <ab@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
13 months agos3/wscript: fix flex detection
Ralph Boehme [Wed, 5 Sep 2018 11:47:17 +0000 (13:47 +0200)]
s3/wscript: fix flex detection

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
13 months agos3/wscript: fix bison detection
Ralph Boehme [Wed, 5 Sep 2018 11:46:37 +0000 (13:46 +0200)]
s3/wscript: fix bison detection

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
13 months agos4/selftest/tests: Enabled samba.tests.samba_tool.computer
Noel Power [Thu, 26 Apr 2018 17:23:50 +0000 (18:23 +0100)]
s4/selftest/tests: Enabled samba.tests.samba_tool.computer

Signed-off-by: Noel Power <noel.power@suse.com>
Reviewed-by: Andrew Bartlett abartlet@samba.org
Autobuild-User(master): Noel Power <npower@samba.org>
Autobuild-Date(master): Thu Sep  6 19:24:54 CEST 2018 on sn-devel-144

13 months agos4/dsdb/tests: port samba4.tombstone_reanimation for PY3
Noel Power [Mon, 3 Sep 2018 17:47:20 +0000 (18:47 +0100)]
s4/dsdb/tests: port samba4.tombstone_reanimation for PY3

Signed-off-by: Noel Power <noel.power@suse.com>
Reviewed-by: Andrew Bartlett abartlet@samba.org
13 months agos3/selftst: enable samba4.tombstone_reanimation for py3
Noel Power [Thu, 10 May 2018 17:17:29 +0000 (18:17 +0100)]
s3/selftst: enable samba4.tombstone_reanimation for py3

Signed-off-by: Noel Power <noel.power@suse.com>
Reviewed-by: Andrew Bartlett abartlet@samba.org
13 months agos4/selftest: enable samba4.drs.replica_sync_rodc.python for py3
Noel Power [Thu, 10 May 2018 16:19:47 +0000 (17:19 +0100)]
s4/selftest: enable samba4.drs.replica_sync_rodc.python for py3

Signed-off-by: Noel Power <noel.power@suse.com>
Reviewed-by: Andrew Bartlett abartlet@samba.org
13 months agos4/torture/drs: PY3 port for samba4.drs.replica_sync_rodc
Noel Power [Mon, 3 Sep 2018 16:56:56 +0000 (17:56 +0100)]
s4/torture/drs: PY3 port for samba4.drs.replica_sync_rodc

Signed-off-by: Noel Power <noel.power@suse.com>
Reviewed-by: Andrew Bartlett abartlet@samba.org
13 months agos4/selftest: enable samba.tests.dsdb_schema_attributes for py3
Noel Power [Thu, 10 May 2018 15:35:29 +0000 (16:35 +0100)]
s4/selftest: enable samba.tests.dsdb_schema_attributes for py3

Signed-off-by: Noel Power <noel.power@suse.com>
Reviewed-by: Andrew Bartlett abartlet@samba.org
13 months agopython/samba/tests: port samba.tests.dsdb_schema_attributes to PY3
Noel Power [Mon, 3 Sep 2018 16:34:27 +0000 (17:34 +0100)]
python/samba/tests: port samba.tests.dsdb_schema_attributes to PY3

Signed-off-by: Noel Power <noel.power@suse.com>
Reviewed-by: Andrew Bartlett abartlet@samba.org
13 months agoPEP8: fix E128: continuation line under-indented for visual indent
Joe Guo [Mon, 3 Sep 2018 13:05:52 +0000 (01:05 +1200)]
PEP8: fix E128: continuation line under-indented for visual indent

Signed-off-by: Joe Guo <joeg@catalyst.net.nz>
Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Thu Sep  6 15:50:17 CEST 2018 on sn-devel-144

13 months agoPEP8: fix E127: continuation line over-indented for visual indent
Joe Guo [Mon, 3 Sep 2018 13:05:48 +0000 (01:05 +1200)]
PEP8: fix E127: continuation line over-indented for visual indent

Signed-off-by: Joe Guo <joeg@catalyst.net.nz>
Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
13 months agoPEP8: fix E125: continuation line with same indent as next logical line
Joe Guo [Mon, 3 Sep 2018 13:05:32 +0000 (01:05 +1200)]
PEP8: fix E125: continuation line with same indent as next logical line

Signed-off-by: Joe Guo <joeg@catalyst.net.nz>
Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
13 months agoPEP8: fix E124: closing bracket does not match visual indentation
Joe Guo [Mon, 3 Sep 2018 13:05:31 +0000 (01:05 +1200)]
PEP8: fix E124: closing bracket does not match visual indentation

Signed-off-by: Joe Guo <joeg@catalyst.net.nz>
Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>