1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-25 23:21:54 +03:00
Commit Graph

3383 Commits

Author SHA1 Message Date
Andrew Bartlett
489f528857 param: Merge param headers into lib/param/loadparm.h
This defines a common table format, so we can in future define a
common table.

Andrew Bartlett
2011-06-29 15:44:09 +10:00
Andrew Bartlett
4d2c56c4b1 s3-net: Bind our gettext results to 'unix charset'
This ensures that the translations and any embedded strings are in the
same charset.  It won't be the one from the user's locale (we no
longer auto-detect that), but it will be self-consistent.

Thanks to Steve Langasek for pointing this function out!

Andrew Bartlett
2011-06-23 13:47:27 +02:00
Rusty Russell
d925b327f4 tdb_compat: Higher level API fixes.
My previous patches fixed up all direct TDB callers, but there are a
few utility functions and the db_context functions which are still
using the old -1 / 0 return codes.

It's clearer to fix up all the callers of these too, so everywhere is
consistent: non-zero means an error.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2011-06-20 11:18:35 +02:00
Rusty Russell
3a8faefd66 tdb_compat: use tdb_firstkey_compat/tdb_nextkey_compat everywhere.
Note that tdb_nextkey_compat frees the old key for us.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2011-06-20 11:18:35 +02:00
Rusty Russell
5a7874e119 tdb_traverse/tdb_traverse_read: check returns for negative, not -1.
TDB2 returns a negative error number on failure.  This is compatible
if we always check for < 0 instead of == -1.

Also, there's no tdb_traverse_read in TDB2: we don't try to make
traverse reliable any more, so there are no write locks anyway.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2011-06-20 11:18:35 +02:00
Rusty Russell
058c4f8492 tdb_fetch_compat: use instead of tdb_fetch.
This is a noop for tdb1.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2011-06-20 11:18:35 +02:00
Stefan Metzmacher
5d736d8777 s3:utils/net_*registry: use c99 initializers which are supported by old gcc 2.95 compilers (bug #8226)
metze

Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Wed Jun 15 03:48:41 CEST 2011 on sn-devel-104
2011-06-15 03:48:41 +02:00
Christian Ambach
7639684f27 s3-utils: fix crash in net cache get
free the blob correctly

Autobuild-User: Christian Ambach <ambi@samba.org>
Autobuild-Date: Tue Jun 14 12:01:59 CEST 2011 on sn-devel-104
2011-06-14 12:01:59 +02:00
Michael Adam
730ea92208 s3:net conf addshare: do not stat-check the share path.
Allow paths with % macros and paths that do not (yet...) exist.

Autobuild-User: Michael Adam <obnox@samba.org>
Autobuild-Date: Fri Jun 10 17:38:07 CEST 2011 on sn-devel-104
2011-06-10 17:38:07 +02:00
Andrew Bartlett
74eed8f3ed s3-param Remove special case for global_myname(), rename to lp_netbios_name()
There is no reason this can't be a normal constant string in the
loadparm system, now that we have lp_set_cmdline() to handle overrides
correctly.

Andrew Bartlett
2011-06-09 12:40:09 +02:00
Andrew Bartlett
f348d148b4 s3-param Remove special case for global_scope()
There is no reason this can't be a normal constant string in the
loadparm system.  (Past reasons were that we didn't have lp_set_cmdline())

Andrew Bartlett
2011-06-09 12:40:09 +02:00
Andrew Bartlett
16b1c77644 lib/util Bring procid_str() into lib/util as server_id_string()
This is needed for OpenChange, which prints Samba struct server_id
values in debug messages.

Andrew Bartlett
2011-06-09 12:40:09 +02:00
Andrew Bartlett
5e26e94092 s3-talloc Change TALLOC_ZERO_ARRAY() to talloc_zero_array()
Using the standard macro makes it easier to move code into common, as
TALLOC_ZERO_ARRAY isn't standard talloc.
2011-06-09 12:40:08 +02:00
Andrew Bartlett
ad0a07c531 s3-talloc Change TALLOC_ZERO_P() to talloc_zero()
Using the standard macro makes it easier to move code into common, as
TALLOC_ZERO_P isn't standard talloc.
2011-06-09 12:40:08 +02:00
Andrew Bartlett
d5e6a47f06 s3-talloc Change TALLOC_P() to talloc()
Using the standard macro makes it easier to move code into common, as
TALLOC_P isn't standard talloc.
2011-06-09 12:40:08 +02:00
Andrew Bartlett
3d15137653 s3-talloc Change TALLOC_ARRAY() to talloc_array()
Using the standard macro makes it easier to move code into common, as
TALLOC_ARRAY isn't standard talloc.
2011-06-09 12:40:08 +02:00
Andrew Bartlett
73b377432c s3-talloc Change TALLOC_REALLOC_ARRAY() to talloc_realloc()
Using the standard macro makes it easier to move code into common, as
TALLOC_REALLOC_ARRAY isn't standard talloc.

Andrew Bartlett
2011-06-09 12:40:08 +02:00
Volker Lendecke
10f5fa8a1e s3: Make use of name_resolve_bcast in nmblookup 2011-06-05 14:08:01 +02:00
Jeremy Allison
c06a31dd65 Fix const warnings.
Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Thu Jun  2 01:02:53 CEST 2011 on sn-devel-104
2011-06-02 01:02:53 +02:00
Jeremy Allison
cbfe8029a4 Fix const warning. 2011-06-01 23:53:07 +02:00
Jeremy Allison
24ce9d52a6 Fix const warning. 2011-06-01 23:53:07 +02:00
Günther Deschner
f103e0c39f s3: fix more -Wunused-but-set-variable build warnings.
Guenther

Autobuild-User: Günther Deschner <gd@samba.org>
Autobuild-Date: Wed Jun  1 00:29:30 CEST 2011 on sn-devel-104
2011-06-01 00:29:30 +02:00
Günther Deschner
4ac4ad2108 s3-utils: fix another -Wunused-but-set-variable build warning.
Guenther

Autobuild-User: Günther Deschner <gd@samba.org>
Autobuild-Date: Tue May 31 05:18:42 CEST 2011 on sn-devel-104
2011-05-31 05:18:42 +02:00
Sumit Bose
e10f27d575 Improve documentation for net rpc trust
Add man pages entries and fix usage output.

Signed-off-by: Günther Deschner <gd@samba.org>

Autobuild-User: Günther Deschner <gd@samba.org>
Autobuild-Date: Mon May 30 20:05:34 CEST 2011 on sn-devel-104
2011-05-30 20:05:34 +02:00
Gregor Beck
723ba6024c s3:net: registry export: close key after recursion returns
Signed-off-by: Michael Adam <obnox@samba.org>

Autobuild-User: Michael Adam <obnox@samba.org>
Autobuild-Date: Mon May 30 18:53:28 CEST 2011 on sn-devel-104
2011-05-30 18:53:28 +02:00
Michael Adam
0d746f653e s3:net registry: polish output of net registry enumerate[_recursive]
so that net registry enumerate output is as before, and
net registry enumerate_recursive is formatted more nicely
2011-05-30 17:42:27 +02:00
Gregor Beck
5ec479fa0c s3:net: registry: use recursive implementation for enumerate
Signed-off-by: Michael Adam <obnox@samba.org>
2011-05-30 17:42:27 +02:00
Gregor Beck
22011ddc9e s3:net: registry: add new command enumerate_recursive
Signed-off-by: Michael Adam <obnox@samba.org>
2011-05-30 17:42:27 +02:00
Gregor Beck
c967e8fae5 s3:smbcacls: fix parsing of multiple flags
Signed-off-by: Michael Adam <obnox@samba.org>
2011-05-30 17:42:27 +02:00
Volker Lendecke
797316ae97 s3: Use cli_connect_nb in net_rpc_check
Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Sat May 28 21:57:04 CEST 2011 on sn-devel-104
2011-05-28 21:57:04 +02:00
Volker Lendecke
54970f90f6 s3: Use cli_connect_nb in cli_servertime 2011-05-28 20:50:10 +02:00
Andrew Bartlett
ee0ee5e925 s3-testparm Warn about incorrect use of 'password server'
This merges master with v3-6-test

Autobuild-User: Andrew Bartlett <abartlet@samba.org>
Autobuild-Date: Wed May 25 05:20:57 CEST 2011 on sn-devel-104
2011-05-25 05:20:57 +02:00
Stefan Metzmacher
1e472f1534 s3:testparm: don't return an error for a warning message
metze

Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Fri May 20 13:14:39 CEST 2011 on sn-devel-104
2011-05-20 13:14:38 +02:00
Andrew Bartlett
06435acf3b s3-testparm Warn more on incorrect use of 'password server' 2011-05-18 16:12:08 +02:00
Andrew Bartlett
3c8de7dd66 lib/util/charset Don't allow invalid 'dos charset = utf8'
No DOS client used UTF8, and this creates subtle, difficult to
disagnose breakage of schannel (domain membership).

Andrew Bartlett
2011-05-18 16:12:08 +02:00
Andrew Bartlett
da662b82b8 s3-lib Replace StrnCaseCmp() with strncasecmp_m()
strncasecmp_m() never needs to call to talloc, and via next_codepoint()
still has an ASCII fast-path bypassing iconv() calls.

Andrew Bartlett
2011-05-18 16:12:08 +02:00
Andrew Bartlett
c615ebed6e s3-lib Replace StrCaseCmp() with strcasecmp_m()
strcasecmp_m() never needs to call to talloc, and via next_codepoint()
still has an ASCII fast-path bypassing iconv() calls.

Andrew Bartlett
2011-05-18 16:12:08 +02:00
Björn Baumbach
25f1583b9f s3-net_rpc_printer.c: Fix cli_errstr() usage (part of bug #7864)
Convert cli_errstr() to nt_errstr()

Signed-off-by: Stefan Metzmacher <metze@samba.org>
2011-05-18 10:53:45 +02:00
Günther Deschner
3d100216b8 s3-net: fix potential crash bug in display_print_driver3().
Guenther

Autobuild-User: Günther Deschner <gd@samba.org>
Autobuild-Date: Fri May 13 18:49:06 CEST 2011 on sn-devel-104
2011-05-13 18:49:06 +02:00
Andreas Schneider
4d391d29f8 libsmbconf: Convert smbconf_get_config() to sbcErr.
Signed-off-by: Michael Adam <obnox@samba.org>
2011-05-10 19:13:22 +02:00
Andreas Schneider
e1f0b91c5f libsmbconf: Convert smbconf_transaction_*() to sbcErr.
Signed-off-by: Michael Adam <obnox@samba.org>
2011-05-10 19:13:22 +02:00
Andreas Schneider
72d15f0c03 libsmbconf: Convert smbconf_delete_includes() to sbcErr.
Signed-off-by: Michael Adam <obnox@samba.org>
2011-05-10 19:13:22 +02:00
Andreas Schneider
d911bafea6 libsmbconf: Convert smbconf_set_includes() to sbcErr.
Signed-off-by: Michael Adam <obnox@samba.org>
2011-05-10 19:13:22 +02:00
Andreas Schneider
9f9711490a libsmbconf: Convert smbconf_get_includes() to sbcErr.
Signed-off-by: Michael Adam <obnox@samba.org>
2011-05-10 19:13:21 +02:00
Andreas Schneider
e19c4f278b libsmbconf: Convert smbconf_delete_parameter() to sbcErr.
Signed-off-by: Michael Adam <obnox@samba.org>
2011-05-10 19:13:21 +02:00
Andreas Schneider
ff5838d97a libsmbconf: Convert smbconf_get_parameter() to sbcErr.
Signed-off-by: Michael Adam <obnox@samba.org>
2011-05-10 19:13:21 +02:00
Andreas Schneider
ddc28a683f libsmbconf: Convert smbconf_set_parameter() to sbcErr.
Signed-off-by: Michael Adam <obnox@samba.org>
2011-05-10 19:13:21 +02:00
Andreas Schneider
fbd7626656 libsmbconf: Convert smbconf_delete_share() to sbcErr.
Signed-off-by: Michael Adam <obnox@samba.org>
2011-05-10 19:13:21 +02:00
Andreas Schneider
7f355e05f9 libsmbconf: Convert smbconf_get_share() to sbcErr.
Signed-off-by: Michael Adam <obnox@samba.org>
2011-05-10 19:13:21 +02:00
Andreas Schneider
7af2876e45 libsmbconf: Convert smbconf_create_share() to smbErr.
Signed-off-by: Michael Adam <obnox@samba.org>
2011-05-10 19:13:20 +02:00