1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-24 21:34:56 +03:00
Commit Graph

2507 Commits

Author SHA1 Message Date
Michael Adam
2b9299310f loadparm: fix a load of uninitialized memory errors found by valgrind. 2012-02-03 11:10:29 +01:00
Jelmer Vernooij
e3dac4b61a replace: Only add bsd dependency when bsd library was found.
Autobuild-User: Jelmer Vernooij <jelmer@samba.org>
Autobuild-Date: Thu Feb  2 05:18:45 CET 2012 on sn-devel-104
2012-02-02 05:18:45 +01:00
Rusty Russell
b3fb115a39 tdb2: add --disable-tdb2
I thought you could --disable-tdb2=false, apparently not!  Thanks
Michael Adam...

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>

Autobuild-User: Rusty Russell <rusty@rustcorp.com.au>
Autobuild-Date: Thu Feb  2 03:43:08 CET 2012 on sn-devel-104
2012-02-02 03:43:08 +01:00
Andrew Bartlett
eecf2ac4c8 selftest: Remove unused support for --exeext 2012-02-01 02:45:07 +01:00
Jelmer Vernooij
5931e1da87 replace: Add include for bsd/string.h. 2012-02-01 01:07:11 +01:00
Ira Cooper
a1901b55cf Fix bug #8729 - getpass regressions on Solaris/Illumos - 3.6 and master.
Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Tue Jan 31 23:28:09 CET 2012 on sn-devel-104
2012-01-31 23:28:09 +01:00
Amitay Isaacs
2343703985 tevent: Fix python documentation strings
Autobuild-User: Amitay Isaacs <amitay@samba.org>
Autobuild-Date: Tue Jan 31 16:59:29 CET 2012 on sn-devel-104
2012-01-31 16:59:29 +01:00
Jelmer Vernooij
c83ce7bcc6 replace: Only include C files from which there are actually functions used.
Autobuild-User: Jelmer Vernooij <jelmer@samba.org>
Autobuild-Date: Tue Jan 31 15:21:04 CET 2012 on sn-devel-104
2012-01-31 15:21:04 +01:00
Jelmer Vernooij
5c50e08983 replace: use libbsd for strlcat/strlcpy when available. 2012-01-31 13:44:17 +01:00
Rusty Russell
7c6713e78f tdb2: make --enable-tdb2 the default.
We still use the tdb1 on-disk format, but we do so via the tdb2 library.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>

Autobuild-User: Rusty Russell <rusty@rustcorp.com.au>
Autobuild-Date: Mon Jan 30 08:02:43 CET 2012 on sn-devel-104
2012-01-30 08:02:42 +01:00
Rusty Russell
e1665c94ac tdb2: add -1 and -2 options to tdbtorture
(For now, -1 is the default).
2012-01-30 15:59:16 +10:30
Rusty Russell
10230829df tdb2:tdbtorture: use TEST_DATA_PREFIX for files
TDB2 version of commit b83672b36c.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2012-01-30 15:31:05 +10:30
Rusty Russell
45ae436b19 tdb2: name tools the same as TDB1 tools.
Otherwise, when we switch everyone's scripts will break (including our
own tests!).

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2012-01-30 10:07:18 +10:30
Rusty Russell
23f1f5e0e3 tdb2: tools/tdb2backup
Minor changes from tdb/tools/tdbbackup.c.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2012-01-30 10:07:17 +10:30
Rusty Russell
dd1d57370d tdb_compat: only use hashsize attribute when O_CREAT
tdb2 complains if you specify a tdb1 hashsize, and you're not actually
trying to create a new database.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2012-01-30 10:06:55 +10:30
Rusty Russell
ae62d46a9f ldb_wrap.c: fix TDB2-incompatible API usage.
Auditing revealed one place still expecting a -1 return on failure:
tdb2 returns the (negative) errcode directly, so the portable way to
do this is to check for != 0.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2012-01-30 09:25:50 +10:30
Rusty Russell
efbf52b4fe tdb2: copy tdb1's changed expansion logic.
TDB2 uses the same expansion logic as TDB1, which got factored out
recently.  So update TDB2 to match.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
(Imported from CCAN commit c438ec17d7b2efe76e56e5fc5ab88bd4a02735e8)
2012-01-30 09:24:50 +10:30
Rusty Russell
205e198471 tdb2: careful on wrap.
It's much harder to wrap a 64-bit tdb2 than a 32-bit tdb1, but we should still
take care against bugs.

Also, we should *not* cast the length to a size_t when comparing it to
the stat result, in case size_t is 32 bit.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
(Imported from CCAN commit 6f7cb26e589cea081e71c59801eae87178967861)
2012-01-30 09:23:50 +10:30
Andreas Schneider
390734acca lib: Remove dead mszip code.
RIP, long live zlib.
2012-01-25 11:58:26 +01:00
Volker Lendecke
e9d66999c6 Introduce dump_data_file
Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Wed Jan 25 11:57:18 CET 2012 on sn-devel-104
2012-01-25 11:57:18 +01:00
Kelly Yeoh
34e7d960d0 ldbedit: prevent a transaction warning on failure
if a modify fails then cancel the transaction to prevent a dangling
transaction error

Signed-off-by: Andrew Tridgell <tridge@samba.org>

Autobuild-User: Andrew Tridgell <tridge@samba.org>
Autobuild-Date: Wed Jan 25 07:06:40 CET 2012 on sn-devel-104
2012-01-25 07:06:40 +01:00
Andrew Bartlett
39ee332f35 param: handle P_BYTES in more places 2012-01-21 11:32:06 +01:00
Stefan Metzmacher
d7dcbcc42d lib/param: avoid talloc_reference() in copy_service()
The memory reduction compared of talloc_reference() over talloc_strdup()
is typically very low. As the strings are typically short compared
to the talloc header overhead.

metze

Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Wed Jan 11 16:13:50 CET 2012 on sn-devel-104
2012-01-11 16:13:50 +01:00
Stefan Metzmacher
91ffcdd5a9 talloc/testsuite: fix compiler warnings
metze

Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Tue Jan 10 13:31:33 CET 2012 on sn-devel-104
2012-01-10 13:31:33 +01:00
Ira Cooper
eff69aa0f9 Add "repack" command to tdbtool.
Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Sat Jan  7 02:18:41 CET 2012 on sn-devel-104
2012-01-07 02:18:40 +01:00
Ira Cooper
7b42ceb414 Fix compile when TDB_TRACE is enabled.
Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Fri Jan  6 04:16:41 CET 2012 on sn-devel-104
2012-01-06 04:16:41 +01:00
Matthieu Patou
f05edc0ecb pyldb: raise an exception if we can't add the attribute 2012-01-03 06:47:10 +01:00
Matthias Dieter Wallnöfer
9ab7299b32 ldb:ldb/common/ldb_controls.c - reference "err_string" variable correctly
Signed-off-by: Stefan Metzmacher <metze@samba.org>
2012-01-02 19:10:04 +01:00
Volker Lendecke
ad3c0e03e2 talloc: Slightly simplify talloc_unlink
Nested if's are hard to understand to me.

Signed-off-by: Stefan Metzmacher <metze@samba.org>

Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Mon Jan  2 19:07:23 CET 2012 on sn-devel-104
2012-01-02 19:07:23 +01:00
Volker Lendecke
0bee8719b2 talloc: Fix a typo 2012-01-02 14:59:59 +01:00
Andrew Bartlett
4b7b26e3c0 gensec: Allow an alternate set of modules to be specified
This will allow s3 to specify modules to use as a list, rather than
needing to start the individual module with gensec_start_mech_by_ops()

Andrew Bartlett
2011-12-28 22:39:19 +11:00
Volker Lendecke
1364eb7bd7 lib/charset: Remove an unused variable
Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Sun Dec 25 15:07:56 CET 2011 on sn-devel-104
2011-12-25 15:07:55 +01:00
Volker Lendecke
b2eaa9afd3 s3: Fix fn signatures in charset_macosx.c 2011-12-25 13:31:58 +01:00
Volker Lendecke
1eefd6bafb tdb: Use tdb_parse_record in tdb_update_hash
This avoids a tdb_fetch, thus a malloc/memcpy/free in the tdb_store path
2011-12-25 13:31:58 +01:00
Volker Lendecke
c1e9537ed0 tdb: Use tdb_parse_record in tdb_update_hash
This avoids a tdb_fetch, thus a malloc/memcpy/free in the tdb_store path
2011-12-25 13:31:58 +01:00
Volker Lendecke
c3a4057a21 libreplace: Don't check for standards.h on darwin (Lion)
standards.h on Lion holds a #warning that standards.h will be removed. This is
annoying during the build.
2011-12-25 13:31:58 +01:00
Matthias Dieter Wallnöfer
eddf0d0fe2 ldb:ldb_tdb.c - fix warnings in "ltdb_init_rootdse"
We should ignore the LDB result.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
2011-12-23 10:36:07 +01:00
Amitay Isaacs
20e425f7a8 ldif-handler: Fix the case for attribute dnsproperty 2011-12-23 16:18:25 +11:00
Stefan Metzmacher
d855e77c69 lib/param: add support for "SMB2_24" in smb.conf options
metze
2011-12-22 15:58:46 +01:00
Andrew Tridgell
4ecac6067f runcmd: use set_close_on_exec()
this prevents a fd leak to child processes

Autobuild-User: Andrew Bartlett <abartlet@samba.org>
Autobuild-Date: Thu Dec 22 14:00:06 CET 2011 on sn-devel-104
2011-12-22 14:00:06 +01:00
Andrew Tridgell
81c564798c runcmd: use a pipe for stdin to child processes
this allows child processes to detect the exit of the parent by
looking for EOF on stdin
2011-12-22 12:26:08 +01:00
Amitay Isaacs
8303d163cf param: domain_logons and domain_master are of type enum_bool_auto
These parameters should be defined as int and not bool. This fixes
the test failures on big endian machines.

Autobuild-User: Amitay Isaacs <amitay@samba.org>
Autobuild-Date: Thu Dec 22 10:37:42 CET 2011 on sn-devel-104
2011-12-22 10:37:42 +01:00
Amitay Isaacs
cd772e9bd8 param: Fix the data type for bAvailable
This causes the copy_service() to not copy bAvailable boolean on
big endian machines causing tests to fail.

Autobuild-User: Amitay Isaacs <amitay@samba.org>
Autobuild-Date: Thu Dec 22 05:30:49 CET 2011 on sn-devel-104
2011-12-22 05:30:49 +01:00
Rusty Russell
5767224b7f tdb: don't free old recovery area when expanding if already at EOF.
We allocate a new recovery area by expanding the file.  But if the
recovery area is already at the end of file (as shown in at least one
client case), we can simply expand the record, rather than freeing it
and creating a new one.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>

Autobuild-User: Rusty Russell <rusty@rustcorp.com.au>
Autobuild-Date: Wed Dec 21 06:25:40 CET 2011 on sn-devel-104
2011-12-21 06:25:40 +01:00
Rusty Russell
3a2a755e33 tdb: use same expansion factor logic when expanding for new recovery area.
If we're expanding because the current recovery area is too small, we
expand only the amount we need.  This can quickly lead to exponential
growth when we have a slowly-expanding record (hence a
slowly-expanding transaction size).

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2011-12-21 14:17:16 +10:30
Volker Lendecke
bfc74811d0 tdb2: Avoid a malloc/memcpy in _tdb1_store
Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Mon Dec 19 16:53:40 CET 2011 on sn-devel-104
2011-12-19 16:53:39 +01:00
Volker Lendecke
664add1775 tdb: Avoid a malloc/memcpy in _tdb_store 2011-12-19 15:18:08 +01:00
Rusty Russell
b64494535d tdb: be more careful on 4G files.
I came across a tdb which had wrapped to 4G + 4K, and the contents had been
destroyed by processes which thought it only 4k long.  Fix this by checking
on open, and making tdb_oob() check for wrap itself.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>

Autobuild-User: Rusty Russell <rusty@rustcorp.com.au>
Autobuild-Date: Mon Dec 19 07:52:01 CET 2011 on sn-devel-104
2011-12-19 07:52:01 +01:00
Volker Lendecke
79fe4bbf73 s3: Fix the clustering build
ctdb_private.h already defines set_close_on_exec.

Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Sat Dec 17 18:41:39 CET 2011 on sn-devel-104
2011-12-17 18:41:39 +01:00
Kai Blin
b1fdf4065e s4 dns: Allow updates based on smb.conf setting
Autobuild-User: Kai Blin <kai@samba.org>
Autobuild-Date: Sat Dec 17 04:19:40 CET 2011 on sn-devel-104
2011-12-17 04:19:40 +01:00