The branch, master has been updated via e079ffd script/autobuild.py: build 'samba' using --picky-developer via 7c7d3eb wafsamba: change the default to allow_warnings=False for CURRENT_CFLAGS() via 994eea6 wafsamba: change the default to allow_warnings=False for SAMBA_{SUBSYSTEM,LIBRARY,MODULE}() via f0db9be s4:ntvfs/unixuid: remove unused allow_warnings=True via a543bfd s4:librpc: remove unused allow_warnings=True for 'dcerpc' via 305e554 s4:lib/messaging: remove unused allow_warnings=True via e474561 s4:lib/events: remove unused allow_warnings=True via 989eb5d wafsamba: use -Wno-error=deprecated-declarations in picky-developer mode via 6f5143d s4:torture: remove unused allow_warnings=True for 'TORTURE_BASIC' and 'TORTURE_VFS' via 5e28f4d s4:torture/winbind: remove unused variables in struct_based.c via d6ce618 s4:torture/locktest: comment out unused code and avoid smbcli_nt_error() via 4a0c260 s4:smb_server/smb2: remove unused _pad variables via de9cd39 s4:smb_server/smb2: avoid unused warnings in smb2srv_setinfo_send() via fcc4a15 s4:ntvfs/smb2: ifdef out unused code via 3e9cc50 s4:ntvfs: explicitly handle RAW_FILEINFO_UNIX_{BASIC,LINK} in ntvfs_map_fileinfo() via b3e33ea s4:nbt_server: avoid str_list related const warning via 4bb9aca s4:kdc: remove unused allow_warnings=True for 'MIT_SAMBA' via e5e5c22 s4:kdc: comment out unused code in db-glue.c via ff732ed s4:libcli/raw: use smb_setfsinfo_level in smb_setfsinfo via c066506 s4:lib/registry: remove unused allow_warnings=True via ea132fd s4:lib/registry: fix compiler warnings via dac1590 s4:lib/registry: avoid some const warnings via 8fd59a8 s3:wscript_build: remove unused allow_warnings=True for 'KRBCLIENT' via 111269d s3:winbindd: make use of talloc_string_sub2() in generate_krb5_ccache() via a5f35ed s3:winbindd: avoid invalid pointer type warnings via 5d070d9 s3:utils: rename variables in regedit_*.c to fix shadow warnings via 002a1c5 s3:utils: add debug functions instead of magic format strings in net_idmap_check.c via c55a4e0 s3:torture: avoid nesting of macros and function calls in torture_cli_session_setup2() via 655d6b5 s3:smbd: avoid a compiler warning in open_sockets_smbd() via 7b537bc s3:smbd: do casting of dm_sessid_t in steps via a1e6db5 s3:wscript_build: remove unused allow_warnings=True for 'smbregistry' via 7a0b8a9 s3:registry: use discard_const_p() to avoid const warning in smb_iconv() define via fe40ee1 s3:printing: fix some const warnings in print_iprint.c via 6c35082 s3:printing: Avoid compiler warning about unused label via 7ec8401 s3:passdb: avoid invalid pointer type warnings in pdb_wbc_sam.c via 966192e s3:passdb: always copy the history in pdb_set_plaintext_passwd() via e9bea35 s3:wscript_build: remove unused allow_warnings=True for 'param' via bdba7a8 s3:param: fix compiler warnings via dd17204 s3:modules: remove unused allow_warnings=True for non_posix_acls, and vfs_media_harmony via 522c715 s3:modules: rename variables in vfs_fruit.c to fix shadow warnings via 768ec14 s3:librpc/idl: mark struct smbXsrv_client as [public] via d63904e s3:wscript_build: remove unused allow_warnings=True for 'ads' via f53c7c30 s3:libads: avoid some compiler warnings in ldap.c via 559016a s3:libsmb: remove unused variables in cliconnect.c via 1669e5c s3:lib/netapi/examples: fix pointer from integer error in nltest.c via 1733df2 s3:lib/netapi/tests: fix invalid switch enum level warning via da0ee7d s3:lib: fix/simplify srprs_hex() from 30c0790 lib-pyldb: Block elements should be surrounded by {} in py_msg.setitem()
https://git.samba.org/?p=samba.git;a=shortlog;h=master - Log ----------------------------------------------------------------- commit e079ffd1da6cda8b4554a4fcb94ef31c10dc8f8b Author: Stefan Metzmacher <me...@samba.org> Date: Tue Nov 11 14:54:41 2014 +0100 script/autobuild.py: build 'samba' using --picky-developer This makes sure we don't get unexpected new compiler warnings. Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> Autobuild-User(master): Jeremy Allison <j...@samba.org> Autobuild-Date(master): Tue Nov 25 09:46:30 CET 2014 on sn-devel-104 commit 7c7d3ebb41f25cb9b83b0f027905f9634d450f19 Author: Stefan Metzmacher <me...@samba.org> Date: Wed Feb 26 07:34:51 2014 +0100 wafsamba: change the default to allow_warnings=False for CURRENT_CFLAGS() Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit 994eea61cc77fb84d4c7689b3a2897c3d3a9bfd5 Author: Stefan Metzmacher <me...@samba.org> Date: Wed Feb 26 07:34:51 2014 +0100 wafsamba: change the default to allow_warnings=False for SAMBA_{SUBSYSTEM,LIBRARY,MODULE}() Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit f0db9be1a95e58098ea2078df3fc566b0d39ef1a Author: Stefan Metzmacher <me...@samba.org> Date: Wed Oct 29 12:27:28 2014 +0100 s4:ntvfs/unixuid: remove unused allow_warnings=True Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit a543bfd3b732ef06bb1ed0f78963f148ed7bdca1 Author: Stefan Metzmacher <me...@samba.org> Date: Wed Oct 29 12:27:28 2014 +0100 s4:librpc: remove unused allow_warnings=True for 'dcerpc' Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit 305e554b4173fa29dd465f501ac442f5e92d95d4 Author: Stefan Metzmacher <me...@samba.org> Date: Wed Oct 29 12:27:28 2014 +0100 s4:lib/messaging: remove unused allow_warnings=True Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit e47456143c68239499b20bd7fa3784bc9db1ec59 Author: Stefan Metzmacher <me...@samba.org> Date: Wed Oct 29 12:27:28 2014 +0100 s4:lib/events: remove unused allow_warnings=True Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit 989eb5d8f8125306045a5db5f2fd9f5caf616754 Author: Stefan Metzmacher <me...@samba.org> Date: Thu May 22 10:41:33 2014 +0200 wafsamba: use -Wno-error=deprecated-declarations in picky-developer mode Currently we use too many deprecated function like dcerpc_binding_handle_set_sync_ev() and others, but this should not be a reason to require 'allow_warnings=True'. Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit 6f5143d9e818b71d74da430c1d693153017347e6 Author: Stefan Metzmacher <me...@samba.org> Date: Wed Oct 29 12:26:38 2014 +0100 s4:torture: remove unused allow_warnings=True for 'TORTURE_BASIC' and 'TORTURE_VFS' Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit 5e28f4dadd3366eef574ae4be681bf7e5f6396d6 Author: Stefan Metzmacher <me...@samba.org> Date: Wed Oct 29 11:39:39 2014 +0100 s4:torture/winbind: remove unused variables in struct_based.c Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit d6ce6189d20d0615cd861e1cb116e18a085dfc6b Author: Stefan Metzmacher <me...@samba.org> Date: Thu Feb 27 09:08:17 2014 +0100 s4:torture/locktest: comment out unused code and avoid smbcli_nt_error() Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit 4a0c2605ac5c28e8d0ee469b897df746d55e26f4 Author: Stefan Metzmacher <me...@samba.org> Date: Thu Feb 27 09:08:17 2014 +0100 s4:smb_server/smb2: remove unused _pad variables Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit de9cd397a97a3eb494b1d5114415152f916fc5ee Author: Stefan Metzmacher <me...@samba.org> Date: Thu Feb 27 09:08:17 2014 +0100 s4:smb_server/smb2: avoid unused warnings in smb2srv_setinfo_send() op->req and req have the same value. Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit fcc4a158173c9cd1b07e33f49900f38fd85f1028 Author: Stefan Metzmacher <me...@samba.org> Date: Thu Feb 27 09:29:36 2014 +0100 s4:ntvfs/smb2: ifdef out unused code Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit 3e9cc501ab07d6c636882c419918563a9823bf53 Author: Stefan Metzmacher <me...@samba.org> Date: Thu Feb 27 09:29:36 2014 +0100 s4:ntvfs: explicitly handle RAW_FILEINFO_UNIX_{BASIC,LINK} in ntvfs_map_fileinfo() This avoids compiler warnings. Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit b3e33ea5bf262b325a35800ca846b939409024fa Author: Stefan Metzmacher <me...@samba.org> Date: Thu Feb 27 09:29:36 2014 +0100 s4:nbt_server: avoid str_list related const warning Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit 4bb9aca9001747f6781c5a495d52f3dce62e47e2 Author: Stefan Metzmacher <me...@samba.org> Date: Wed Oct 29 12:21:07 2014 +0100 s4:kdc: remove unused allow_warnings=True for 'MIT_SAMBA' Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit e5e5c223531e1935ba3c30b6439bdc0afd53a88d Author: Stefan Metzmacher <me...@samba.org> Date: Thu Feb 27 09:29:36 2014 +0100 s4:kdc: comment out unused code in db-glue.c Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit ff732ed6b590eef25fea3aa651dcbc43cf52a7d6 Author: Stefan Metzmacher <me...@samba.org> Date: Thu Feb 27 09:50:57 2014 +0100 s4:libcli/raw: use smb_setfsinfo_level in smb_setfsinfo Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit c066506cb3539e0658515425d921bd532b4b6a96 Author: Stefan Metzmacher <me...@samba.org> Date: Wed Oct 29 12:25:24 2014 +0100 s4:lib/registry: remove unused allow_warnings=True Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit ea132fd7d1dcf88402cbb0ad9a9cc2c27fdbf04a Author: Stefan Metzmacher <me...@samba.org> Date: Wed Oct 29 12:24:44 2014 +0100 s4:lib/registry: fix compiler warnings Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit dac1590379dff09ba39654daee15afae9c52c92e Author: Stefan Metzmacher <me...@samba.org> Date: Thu Feb 27 09:49:47 2014 +0100 s4:lib/registry: avoid some const warnings Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit 8fd59a828e2c57517da2416ef52742a83bdcb969 Author: Stefan Metzmacher <me...@samba.org> Date: Wed Oct 29 12:21:07 2014 +0100 s3:wscript_build: remove unused allow_warnings=True for 'KRBCLIENT' Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit 111269d484e912e745ebf0852a06d3b5d426fa30 Author: Stefan Metzmacher <me...@samba.org> Date: Wed Feb 26 20:16:26 2014 +0100 s3:winbindd: make use of talloc_string_sub2() in generate_krb5_ccache() This way we don't pass a given format string to talloc_asprintf(). Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit a5f35ed5cfe50be9cfd9d10812fd7534e1a12840 Author: Stefan Metzmacher <me...@samba.org> Date: Wed Feb 26 20:16:26 2014 +0100 s3:winbindd: avoid invalid pointer type warnings Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit 5d070d9f1844ebb120cf254c57f45c3aba9618ef Author: Stefan Metzmacher <me...@samba.org> Date: Thu Nov 13 09:12:56 2014 +0100 s3:utils: rename variables in regedit_*.c to fix shadow warnings Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit 002a1c57a962779372643abf0857e820541c1b0d Author: Stefan Metzmacher <me...@samba.org> Date: Wed Feb 26 20:16:26 2014 +0100 s3:utils: add debug functions instead of magic format strings in net_idmap_check.c This way the compiler can check the format string and doesn't generate warnings. Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit c55a4e0b81ab3f87b7fa0d323d0752aa5ff71c1c Author: Stefan Metzmacher <me...@samba.org> Date: Thu Oct 23 10:18:21 2014 +0200 s3:torture: avoid nesting of macros and function calls in torture_cli_session_setup2() Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit 655d6b508afe6bbb031a4637b3a310b480181136 Author: Stefan Metzmacher <me...@samba.org> Date: Wed Feb 26 20:16:26 2014 +0100 s3:smbd: avoid a compiler warning in open_sockets_smbd() Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit 7b537bc8c1d72842bc1d1fca79265eb77b5b4495 Author: Stefan Metzmacher <me...@samba.org> Date: Wed Feb 26 20:16:26 2014 +0100 s3:smbd: do casting of dm_sessid_t in steps This makes it more explicit and avoids compiler warnings. Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit a1e6db573af18a3b83d08eda41e9aad7cc4ff9cc Author: Stefan Metzmacher <me...@samba.org> Date: Wed Oct 29 12:18:14 2014 +0100 s3:wscript_build: remove unused allow_warnings=True for 'smbregistry' Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit 7a0b8a9a6e785de7024ba873414bbd656e161750 Author: Stefan Metzmacher <me...@samba.org> Date: Wed Feb 26 20:16:26 2014 +0100 s3:registry: use discard_const_p() to avoid const warning in smb_iconv() define I'm wondering why we have this in reg_parse_internal.h at all! But for now just fix warnings... Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit fe40ee148a2861105cf6763263db65cf96bd22d0 Author: Stefan Metzmacher <me...@samba.org> Date: Thu Jul 3 13:14:20 2014 +0200 s3:printing: fix some const warnings in print_iprint.c Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit 6c35082a941d6cabab220958bb24838b1db2d38e Author: Kai Blin <k...@samba.org> Date: Fri Mar 14 09:07:16 2014 +0100 s3:printing: Avoid compiler warning about unused label Signed-off-by: Kai Blin <k...@samba.org> Reviewed-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit 7ec8401f82994070eaaf81ff067c0cd0576d58e3 Author: Stefan Metzmacher <me...@samba.org> Date: Wed Feb 26 20:16:26 2014 +0100 s3:passdb: avoid invalid pointer type warnings in pdb_wbc_sam.c Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit 966192ee16d6802da5c2b046d2488ddd1a7ec960 Author: Stefan Metzmacher <me...@samba.org> Date: Wed Feb 26 20:16:26 2014 +0100 s3:passdb: always copy the history in pdb_set_plaintext_passwd() We should not write to memory marked as const (returned from pdb_get_pw_history())! Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit e9bea35b7dbb516ade273cea1c4273299114aa41 Author: Stefan Metzmacher <me...@samba.org> Date: Wed Oct 29 12:13:23 2014 +0100 s3:wscript_build: remove unused allow_warnings=True for 'param' Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit bdba7a8bcea754e6a9262c9fab7d94da7290db1f Author: Stefan Metzmacher <me...@samba.org> Date: Wed Oct 29 12:12:48 2014 +0100 s3:param: fix compiler warnings Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit dd17204e6fe3e494d3321bb5865a4b4691490564 Author: Stefan Metzmacher <me...@samba.org> Date: Wed Oct 29 12:11:33 2014 +0100 s3:modules: remove unused allow_warnings=True for non_posix_acls, and vfs_media_harmony Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit 522c71531f43b71226191ba6a9f1d02fb8b6b3bf Author: Stefan Metzmacher <me...@samba.org> Date: Thu Nov 13 09:12:56 2014 +0100 s3:modules: rename variables in vfs_fruit.c to fix shadow warnings Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit 768ec14b3c33162f4926d62dc41c4249f2e1904c Author: Stefan Metzmacher <me...@samba.org> Date: Wed Oct 29 12:04:36 2014 +0100 s3:librpc/idl: mark struct smbXsrv_client as [public] This avoids compiler warnings about unused code. We don't use the NDR code for this yet, will be done when we get multi-channel support. Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit d63904ef6c02069c5e29e7433a7ee09758571590 Author: Stefan Metzmacher <me...@samba.org> Date: Wed Oct 29 12:21:07 2014 +0100 s3:wscript_build: remove unused allow_warnings=True for 'ads' Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit f53c7c308278187b31ed6fac60e7c7c417c8c77a Author: Stefan Metzmacher <me...@samba.org> Date: Wed Feb 26 20:16:26 2014 +0100 s3:libads: avoid some compiler warnings in ldap.c We use helper variables and explicit casts using discard_const_p() to avoid bogus const warnings. Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit 559016a43986ec303fb5f86a54d61ecd160968ae Author: Stefan Metzmacher <me...@samba.org> Date: Thu Oct 23 10:17:40 2014 +0200 s3:libsmb: remove unused variables in cliconnect.c Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit 1669e5cdecdab35fef276fcf3c45c0e4f475807b Author: Stefan Metzmacher <me...@samba.org> Date: Wed Feb 26 20:16:26 2014 +0100 s3:lib/netapi/examples: fix pointer from integer error in nltest.c Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit 1733df28115b5507ac8db5577100da02c2b6520d Author: Stefan Metzmacher <me...@samba.org> Date: Wed Feb 26 20:16:26 2014 +0100 s3:lib/netapi/tests: fix invalid switch enum level warning Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> commit da0ee7d866bf9713f80c074a509156bd1d8cf86f Author: Stefan Metzmacher <me...@samba.org> Date: Thu Nov 13 08:50:35 2014 +0100 s3:lib: fix/simplify srprs_hex() There're a few problems with this function. - it pretends to support values up to UINT64_MAX in it only returns 'unsigned' which support only values up to UINT32_MAX. Currently we only have callers with len=2 and len=8, so it's not a triggered bug. We just allow (len >= 1 && len <= 8) now. - The compiler is not able to inspect the format string to sscanf(). We copy up to 8 bytes into a stack buffer and always pass "%8x" to sscanf. Signed-off-by: Stefan Metzmacher <me...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> ----------------------------------------------------------------------- Summary of changes: buildtools/wafsamba/samba_autoconf.py | 4 +-- buildtools/wafsamba/wafsamba.py | 6 ++-- script/autobuild.py | 2 +- source3/lib/netapi/examples/netlogon/nltest.c | 2 +- source3/lib/netapi/tests/netgroup.c | 2 +- source3/lib/srprs.c | 16 ++++----- source3/libads/ldap.c | 34 ++++++++++--------- source3/librpc/idl/smbXsrv.idl | 2 +- source3/libsmb/cliconnect.c | 3 -- source3/modules/vfs_fruit.c | 32 +++++++++--------- source3/modules/wscript_build | 2 -- source3/param/loadparm.c | 24 +++++++------- source3/passdb/pdb_get_set.c | 33 ++++++++----------- source3/passdb/pdb_wbc_sam.c | 19 +++++++---- source3/printing/pcap.c | 4 +++ source3/printing/print_iprint.c | 12 +++---- source3/registry/reg_parse_internal.h | 2 +- source3/smbd/dmapi.c | 10 +++--- source3/smbd/server.c | 4 ++- source3/torture/torture.c | 9 ++--- source3/utils/net_idmap_check.c | 47 ++++++++++++++++++++++----- source3/utils/regedit_dialog.c | 14 ++++---- source3/utils/regedit_hexedit.c | 6 ++-- source3/utils/regedit_treeview.c | 14 ++++---- source3/utils/regedit_valuelist.c | 4 +-- source3/winbindd/idmap_nss.c | 4 ++- source3/winbindd/winbindd_msrpc.c | 5 ++- source3/winbindd/winbindd_pam.c | 15 ++++++++- source3/winbindd/winbindd_rpc.c | 5 ++- source3/wscript_build | 4 --- source4/kdc/db-glue.c | 4 +-- source4/kdc/wscript_build | 1 - source4/lib/events/wscript_build | 1 - source4/lib/messaging/wscript_build | 1 - source4/lib/registry/regf.c | 14 +++++--- source4/lib/registry/tools/regpatch.c | 4 +-- source4/lib/registry/tools/regshell.c | 42 ++++++++++++------------ source4/lib/registry/tools/regtree.c | 4 +-- source4/lib/registry/wscript_build | 1 - source4/libcli/raw/interfaces.h | 4 +-- source4/librpc/wscript_build | 1 - source4/nbt_server/wins/winsclient.c | 4 ++- source4/ntvfs/ntvfs_generic.c | 9 +++-- source4/ntvfs/smb2/vfs_smb2.c | 2 ++ source4/ntvfs/unixuid/wscript_build | 1 - source4/smb_server/smb2/fileinfo.c | 2 +- source4/smb_server/smb2/keepalive.c | 4 --- source4/smb_server/smb2/sesssetup.c | 4 --- source4/smb_server/smb2/tcon.c | 4 --- source4/torture/locktest.c | 10 +++--- source4/torture/winbind/struct_based.c | 8 ++--- source4/torture/wscript_build | 2 -- 52 files changed, 258 insertions(+), 209 deletions(-) Changeset truncated at 500 lines: diff --git a/buildtools/wafsamba/samba_autoconf.py b/buildtools/wafsamba/samba_autoconf.py index c193873..9e50ee5 100644 --- a/buildtools/wafsamba/samba_autoconf.py +++ b/buildtools/wafsamba/samba_autoconf.py @@ -691,7 +691,7 @@ int main(void) { conf.env['EXTRA_CFLAGS'].extend(TO_LIST("-Werror=format")) if Options.options.picky_developer: - conf.ADD_NAMED_CFLAGS('PICKY_CFLAGS', '-Werror', testflags=True) + conf.ADD_NAMED_CFLAGS('PICKY_CFLAGS', '-Werror -Wno-error=deprecated-declarations', testflags=True) if Options.options.fatal_errors: conf.ADD_CFLAGS('-Wfatal-errors', testflags=True) @@ -765,7 +765,7 @@ def ADD_EXTRA_INCLUDES(conf, includes): -def CURRENT_CFLAGS(bld, target, cflags, allow_warnings=True, hide_symbols=False): +def CURRENT_CFLAGS(bld, target, cflags, allow_warnings=False, hide_symbols=False): '''work out the current flags. local flags are added first''' ret = TO_LIST(cflags) if not 'EXTRA_CFLAGS' in bld.env: diff --git a/buildtools/wafsamba/wafsamba.py b/buildtools/wafsamba/wafsamba.py index b68b9d2..020516b 100644 --- a/buildtools/wafsamba/wafsamba.py +++ b/buildtools/wafsamba/wafsamba.py @@ -132,7 +132,7 @@ def SAMBA_LIBRARY(bld, libname, source, private_library=False, grouping_library=False, allow_undefined_symbols=False, - allow_warnings=True, + allow_warnings=False, enabled=True): '''define a Samba library''' @@ -420,7 +420,7 @@ def SAMBA_MODULE(bld, modname, source, pyembed=False, manpages=None, allow_undefined_symbols=False, - allow_warnings=True + allow_warnings=False ): '''define a Samba module.''' @@ -520,7 +520,7 @@ def SAMBA_SUBSYSTEM(bld, modname, source, vars=None, subdir=None, hide_symbols=False, - allow_warnings=True, + allow_warnings=False, pyext=False, pyembed=False): '''define a Samba subsystem''' diff --git a/script/autobuild.py b/script/autobuild.py index 2b25a10..ba08e52 100755 --- a/script/autobuild.py +++ b/script/autobuild.py @@ -44,7 +44,7 @@ tasks = { ("clean", "make clean", "text/plain") ], # We have 'test' before 'install' because, 'test' should work without 'install' - "samba" : [ ("configure", "./configure.developer ${PREFIX} --with-selftest-prefix=./bin/ab", "text/plain"), + "samba" : [ ("configure", "./configure.developer --picky-developer ${PREFIX} --with-selftest-prefix=./bin/ab", "text/plain"), ("make", "make -j", "text/plain"), ("test", "make test FAIL_IMMEDIATELY=1", "text/plain"), ("install", "make install", "text/plain"), diff --git a/source3/lib/netapi/examples/netlogon/nltest.c b/source3/lib/netapi/examples/netlogon/nltest.c index f75a995..9f96bda 100644 --- a/source3/lib/netapi/examples/netlogon/nltest.c +++ b/source3/lib/netapi/examples/netlogon/nltest.c @@ -289,7 +289,7 @@ int main(int argc, const char **argv) status = I_NetLogonControl2(opt_server, NETLOGON_CONTROL_SET_DBFLAG, query_level, - (uint8_t *)opt_dbflag, + (uint8_t *)&opt_dbflag, &buffer); if (status != 0) { fprintf(stderr, "I_NetlogonControl failed: Status = %d 0x%x %s\n", diff --git a/source3/lib/netapi/tests/netgroup.c b/source3/lib/netapi/tests/netgroup.c index c872087..dba4fe7 100644 --- a/source3/lib/netapi/tests/netgroup.c +++ b/source3/lib/netapi/tests/netgroup.c @@ -348,7 +348,7 @@ NET_API_STATUS netapitest_group(struct libnetapi_ctx *ctx, printf("testing NetGroupSetInfo level 0\n"); status = NetGroupSetInfo(hostname, groupname, 0, (uint8_t *)&g0, &parm_err); - switch (status) { + switch ((int)status) { case 0: break; case 50: /* not supported */ diff --git a/source3/lib/srprs.c b/source3/lib/srprs.c index 35920f1..a3fd0c3 100644 --- a/source3/lib/srprs.c +++ b/source3/lib/srprs.c @@ -125,26 +125,22 @@ fail: bool srprs_hex(const char** ptr, size_t len, unsigned* u) { - static const char* FMT[] = { - "%1x","%2x","%3x","%4x","%5x","%6x","%7x","%8x", - "%9x","%10x","%11x","%12x","%13x","%14x","%15x","%16x" - }; - - const char* pos = *ptr; + const char *str = *ptr; + const char *pos = *ptr; int ret; int i; + char buf[8+1] = {}; - assert((len > 0) - && (len <= 2*sizeof(unsigned)) - && (len <= sizeof(FMT)/sizeof(const char*))); + assert((len >= 1) && (len <= 8)); for (i=0; i<len; i++) { if (!srprs_charset(&pos, "0123456789abcdefABCDEF", NULL)) { break; } + buf[i] = str[i]; } - ret = sscanf(*ptr, FMT[len-1], u); + ret = sscanf(buf, "%8x", u); if ( ret != 1 ) { return false; diff --git a/source3/libads/ldap.c b/source3/libads/ldap.c index b46f510..5258c8f 100644 --- a/source3/libads/ldap.c +++ b/source3/libads/ldap.c @@ -1436,21 +1436,23 @@ static ADS_STATUS ads_modlist_add(TALLOC_CTX *ctx, ADS_MODLIST *mods, int mod_op, const char *name, const void *_invals) { - const void **invals = (const void **)_invals; int curmod; LDAPMod **modlist = (LDAPMod **) *mods; struct berval **ber_values = NULL; char **char_values = NULL; - if (!invals) { + if (!_invals) { mod_op = LDAP_MOD_DELETE; } else { - if (mod_op & LDAP_MOD_BVALUES) - ber_values = ads_dup_values(ctx, - (const struct berval **)invals); - else - char_values = ads_push_strvals(ctx, - (const char **) invals); + if (mod_op & LDAP_MOD_BVALUES) { + const struct berval **b; + b = discard_const_p(const struct berval *, _invals); + ber_values = ads_dup_values(ctx, b); + } else { + const char **c; + c = discard_const_p(const char *, _invals); + char_values = ads_push_strvals(ctx, c); + } } /* find the first empty slot */ @@ -2418,7 +2420,8 @@ static bool ads_dump_field(ADS_STRUCT *ads, char *field, void **values, void *da utf8_field=ldap_next_attribute(ads->ldap.ld, (LDAPMessage *)msg,b)) { struct berval **ber_vals; - char **str_vals, **utf8_vals; + char **str_vals; + char **utf8_vals; char *field; bool string; @@ -2433,10 +2436,12 @@ static bool ads_dump_field(ADS_STRUCT *ads, char *field, void **values, void *da string = fn(ads, field, NULL, data_area); if (string) { + const char **p; + utf8_vals = ldap_get_values(ads->ldap.ld, (LDAPMessage *)msg, field); - str_vals = ads_pull_strvals(ctx, - (const char **) utf8_vals); + p = discard_const_p(const char *, utf8_vals); + str_vals = ads_pull_strvals(ctx, p); fn(ads, field, (void **) str_vals, data_area); ldap_value_free(utf8_vals); } else { @@ -3277,7 +3282,7 @@ ADS_STATUS ads_get_joinable_ous(ADS_STRUCT *ads, for (msg = ads_first_entry(ads, res); msg; msg = ads_next_entry(ads, msg)) { - + const char **p = discard_const_p(const char *, *ous); char *dn = NULL; dn = ads_get_dn(ads, talloc_tos(), msg); @@ -3286,15 +3291,14 @@ ADS_STATUS ads_get_joinable_ous(ADS_STRUCT *ads, return ADS_ERROR(LDAP_NO_MEMORY); } - if (!add_string_to_array(mem_ctx, dn, - (const char ***)ous, - num_ous)) { + if (!add_string_to_array(mem_ctx, dn, &p, num_ous)) { TALLOC_FREE(dn); ads_msgfree(ads, res); return ADS_ERROR(LDAP_NO_MEMORY); } TALLOC_FREE(dn); + *ous = discard_const_p(char *, p); } ads_msgfree(ads, res); diff --git a/source3/librpc/idl/smbXsrv.idl b/source3/librpc/idl/smbXsrv.idl index 0035442..ec6d0ea 100644 --- a/source3/librpc/idl/smbXsrv.idl +++ b/source3/librpc/idl/smbXsrv.idl @@ -79,7 +79,7 @@ interface smbXsrv /* client */ - typedef struct { + typedef [public] struct { [ignore] struct tevent_context *ev_ctx; [ignore] struct messaging_context *msg_ctx; diff --git a/source3/libsmb/cliconnect.c b/source3/libsmb/cliconnect.c index 789a85d..2b1e2ec 100644 --- a/source3/libsmb/cliconnect.c +++ b/source3/libsmb/cliconnect.c @@ -1732,7 +1732,6 @@ static struct tevent_req *cli_session_setup_spnego_send( char *OIDs[ASN1_MAX_OIDS]; int i; const DATA_BLOB *server_blob; - NTSTATUS status; req = tevent_req_create(mem_ctx, &state, struct cli_session_setup_spnego_state); @@ -3371,8 +3370,6 @@ static void cli_full_connection_done(struct tevent_req *subreq) { struct tevent_req *req = tevent_req_callback_data( subreq, struct tevent_req); - struct cli_full_connection_state *state = tevent_req_data( - req, struct cli_full_connection_state); NTSTATUS status; status = cli_tree_connect_recv(subreq); diff --git a/source3/modules/vfs_fruit.c b/source3/modules/vfs_fruit.c index c1555f0..da1ec7f 100644 --- a/source3/modules/vfs_fruit.c +++ b/source3/modules/vfs_fruit.c @@ -1263,13 +1263,13 @@ static int init_fruit_config(vfs_handle_struct *handle) static int adouble_path(TALLOC_CTX *ctx, const char *path_in, char **path_out) { char *parent; - const char *basename; + const char *base; - if (!parent_dirname(ctx, path_in, &parent, &basename)) { + if (!parent_dirname(ctx, path_in, &parent, &base)) { return -1; } - *path_out = talloc_asprintf(ctx, "%s/._%s", parent, basename); + *path_out = talloc_asprintf(ctx, "%s/._%s", parent, base); if (*path_out == NULL) { return -1; } @@ -1451,7 +1451,7 @@ static void update_btime(vfs_handle_struct *handle, /** * Map an access mask to a Netatalk single byte byte range lock **/ -static off_t access_to_netatalk_brl(enum apple_fork fork, +static off_t access_to_netatalk_brl(enum apple_fork fork_type, uint32_t access_mask) { off_t offset; @@ -1471,7 +1471,7 @@ static off_t access_to_netatalk_brl(enum apple_fork fork, break; } - if (fork == APPLE_FORK_RSRC) { + if (fork_type == APPLE_FORK_RSRC) { if (offset == AD_FILELOCK_OPEN_NONE) { offset = AD_FILELOCK_RSRC_OPEN_NONE; } else { @@ -1485,7 +1485,7 @@ static off_t access_to_netatalk_brl(enum apple_fork fork, /** * Map a deny mode to a Netatalk brl **/ -static off_t denymode_to_netatalk_brl(enum apple_fork fork, +static off_t denymode_to_netatalk_brl(enum apple_fork fork_type, uint32_t deny_mode) { off_t offset; @@ -1503,7 +1503,7 @@ static off_t denymode_to_netatalk_brl(enum apple_fork fork, smb_panic("denymode_to_netatalk_brl: bad deny mode\n"); } - if (fork == APPLE_FORK_RSRC) { + if (fork_type == APPLE_FORK_RSRC) { offset += 2; } @@ -1548,7 +1548,7 @@ static NTSTATUS fruit_check_access(vfs_handle_struct *handle, off_t off; /* FIXME: hardcoded data fork, add resource fork */ - enum apple_fork fork = APPLE_FORK_DATA; + enum apple_fork fork_type = APPLE_FORK_DATA; DEBUG(10, ("fruit_check_access: %s, am: %s/%s, dm: %s/%s\n", fsp_str_dbg(fsp), @@ -1563,10 +1563,10 @@ static NTSTATUS fruit_check_access(vfs_handle_struct *handle, if ((access_mask & FILE_READ_DATA) || (deny_mode & DENY_READ)) { /* Check access */ open_for_reading = test_netatalk_lock( - fsp, access_to_netatalk_brl(fork, FILE_READ_DATA)); + fsp, access_to_netatalk_brl(fork_type, FILE_READ_DATA)); deny_read = test_netatalk_lock( - fsp, denymode_to_netatalk_brl(fork, DENY_READ)); + fsp, denymode_to_netatalk_brl(fork_type, DENY_READ)); DEBUG(10, ("read: %s, deny_write: %s\n", open_for_reading == true ? "yes" : "no", @@ -1579,7 +1579,7 @@ static NTSTATUS fruit_check_access(vfs_handle_struct *handle, /* Set locks */ if (access_mask & FILE_READ_DATA) { - off = access_to_netatalk_brl(fork, FILE_READ_DATA); + off = access_to_netatalk_brl(fork_type, FILE_READ_DATA); br_lck = do_lock( handle->conn->sconn->msg_ctx, fsp, fsp->op->global->open_persistent_id, 1, off, @@ -1593,7 +1593,7 @@ static NTSTATUS fruit_check_access(vfs_handle_struct *handle, } if (deny_mode & DENY_READ) { - off = denymode_to_netatalk_brl(fork, DENY_READ); + off = denymode_to_netatalk_brl(fork_type, DENY_READ); br_lck = do_lock( handle->conn->sconn->msg_ctx, fsp, fsp->op->global->open_persistent_id, 1, off, @@ -1613,10 +1613,10 @@ static NTSTATUS fruit_check_access(vfs_handle_struct *handle, if ((access_mask & FILE_WRITE_DATA) || (deny_mode & DENY_WRITE)) { /* Check access */ open_for_writing = test_netatalk_lock( - fsp, access_to_netatalk_brl(fork, FILE_WRITE_DATA)); + fsp, access_to_netatalk_brl(fork_type, FILE_WRITE_DATA)); deny_write = test_netatalk_lock( - fsp, denymode_to_netatalk_brl(fork, DENY_WRITE)); + fsp, denymode_to_netatalk_brl(fork_type, DENY_WRITE)); DEBUG(10, ("write: %s, deny_write: %s\n", open_for_writing == true ? "yes" : "no", @@ -1629,7 +1629,7 @@ static NTSTATUS fruit_check_access(vfs_handle_struct *handle, /* Set locks */ if (access_mask & FILE_WRITE_DATA) { - off = access_to_netatalk_brl(fork, FILE_WRITE_DATA); + off = access_to_netatalk_brl(fork_type, FILE_WRITE_DATA); br_lck = do_lock( handle->conn->sconn->msg_ctx, fsp, fsp->op->global->open_persistent_id, 1, off, @@ -1643,7 +1643,7 @@ static NTSTATUS fruit_check_access(vfs_handle_struct *handle, } if (deny_mode & DENY_WRITE) { - off = denymode_to_netatalk_brl(fork, DENY_WRITE); + off = denymode_to_netatalk_brl(fork_type, DENY_WRITE); br_lck = do_lock( handle->conn->sconn->msg_ctx, fsp, fsp->op->global->open_persistent_id, 1, off, diff --git a/source3/modules/wscript_build b/source3/modules/wscript_build index e5d04f7..de4947b 100644 --- a/source3/modules/wscript_build +++ b/source3/modules/wscript_build @@ -7,7 +7,6 @@ bld.SAMBA3_SUBSYSTEM('NFS4_ACLS', bld.SAMBA3_LIBRARY('non_posix_acls', source='non_posix_acls.c', deps='samba-util vfs', - allow_warnings=True, private_library=True) bld.SAMBA3_SUBSYSTEM('VFS_AIXACL_UTIL', @@ -439,7 +438,6 @@ bld.SAMBA3_MODULE('vfs_time_audit', bld.SAMBA3_MODULE('vfs_media_harmony', subsystem='vfs', source='vfs_media_harmony.c', - allow_warnings=True, deps='samba-util', init_function='', internal_module=bld.SAMBA3_IS_STATIC_MODULE('vfs_media_harmony'), diff --git a/source3/param/loadparm.c b/source3/param/loadparm.c index f246c28..8494c3f 100644 --- a/source3/param/loadparm.c +++ b/source3/param/loadparm.c @@ -559,7 +559,7 @@ static void init_globals(struct loadparm_context *lp_ctx, bool reinit_globals) init_printer_values(lp_ctx, Globals.ctx, &sDefault); - sDefault.ntvfs_handler = (const char **)str_list_make_v3(NULL, "unixuid default", NULL); + sDefault.ntvfs_handler = str_list_make_v3_const(NULL, "unixuid default", NULL); DEBUG(3, ("Initialising global parameters\n")); @@ -617,7 +617,7 @@ static void init_globals(struct loadparm_context *lp_ctx, bool reinit_globals) string_set(Globals.ctx, &Globals.logon_home, "\\\\%N\\%U"); string_set(Globals.ctx, &Globals.logon_path, "\\\\%N\\%U\\profile"); - Globals.name_resolve_order = (const char **)str_list_make_v3(NULL, "lmhosts wins host bcast", NULL); + Globals.name_resolve_order = str_list_make_v3_const(NULL, "lmhosts wins host bcast", NULL); string_set(Globals.ctx, &Globals.password_server, "*"); Globals.algorithmic_rid_base = BASE_RID; @@ -803,7 +803,7 @@ static void init_globals(struct loadparm_context *lp_ctx, bool reinit_globals) Globals.winbind_trusted_domains_only = false; Globals.winbind_nested_groups = true; Globals.winbind_expand_groups = 0; - Globals.winbind_nss_info = (const char **)str_list_make_v3(NULL, "template", NULL); + Globals.winbind_nss_info = str_list_make_v3_const(NULL, "template", NULL); Globals.winbind_refresh_tickets = false; Globals.winbind_offline_logon = false; @@ -821,7 +821,7 @@ static void init_globals(struct loadparm_context *lp_ctx, bool reinit_globals) Globals.server_signing = SMB_SIGNING_DEFAULT; Globals.defer_sharing_violations = true; - Globals.smb_ports = (const char **)str_list_make_v3(NULL, SMB_PORTS, NULL); + Globals.smb_ports = str_list_make_v3_const(NULL, SMB_PORTS, NULL); Globals.enable_privileges = true; Globals.host_msdfs = true; @@ -858,9 +858,9 @@ static void init_globals(struct loadparm_context *lp_ctx, bool reinit_globals) string_set(Globals.ctx, &Globals.ncalrpc_dir, get_dyn_NCALRPCDIR()); - Globals.server_services = (const char **)str_list_make_v3(NULL, "s3fs rpc nbt wrepl ldap cldap kdc drepl winbindd ntp_signd kcc dnsupdate dns", NULL); + Globals.server_services = str_list_make_v3_const(NULL, "s3fs rpc nbt wrepl ldap cldap kdc drepl winbindd ntp_signd kcc dnsupdate dns", NULL); - Globals.dcerpc_endpoint_servers = (const char **)str_list_make_v3(NULL, "epmapper wkssvc rpcecho samr netlogon lsarpc spoolss drsuapi dssetup unixinfo browser eventlog6 backupkey dnsserver", NULL); + Globals.dcerpc_endpoint_servers = str_list_make_v3_const(NULL, "epmapper wkssvc rpcecho samr netlogon lsarpc spoolss drsuapi dssetup unixinfo browser eventlog6 backupkey dnsserver", NULL); Globals.tls_enabled = true; @@ -882,26 +882,26 @@ static void init_globals(struct loadparm_context *lp_ctx, bool reinit_globals) if (s == NULL) { smb_panic("init_globals: ENOMEM"); } - Globals.samba_kcc_command = (const char **)str_list_make_v3(NULL, s, NULL); + Globals.samba_kcc_command = str_list_make_v3_const(NULL, s, NULL); TALLOC_FREE(s); s = talloc_asprintf(talloc_tos(), "%s/samba_dnsupdate", get_dyn_SCRIPTSBINDIR()); if (s == NULL) { smb_panic("init_globals: ENOMEM"); } - Globals.dns_update_command = (const char **)str_list_make_v3(NULL, s, NULL); + Globals.dns_update_command = str_list_make_v3_const(NULL, s, NULL); TALLOC_FREE(s); s = talloc_asprintf(talloc_tos(), "%s/samba_spnupdate", get_dyn_SCRIPTSBINDIR()); if (s == NULL) { smb_panic("init_globals: ENOMEM"); } - Globals.spn_update_command = (const char **)str_list_make_v3(NULL, s, NULL); + Globals.spn_update_command = str_list_make_v3_const(NULL, s, NULL); TALLOC_FREE(s); - Globals.nsupdate_command = (const char **)str_list_make_v3(NULL, "/usr/bin/nsupdate -g", NULL); + Globals.nsupdate_command = str_list_make_v3_const(NULL, "/usr/bin/nsupdate -g", NULL); - Globals.rndc_command = (const char **)str_list_make_v3(NULL, "/usr/sbin/rndc", NULL); + Globals.rndc_command = str_list_make_v3_const(NULL, "/usr/sbin/rndc", NULL); Globals.cldap_port = 389; @@ -1164,7 +1164,7 @@ const char **lp_parm_string_list(int snum, const char *type, const char *option, data->list = str_list_make_v3(NULL, data->value, NULL); } - return (const char **)data->list; + return discard_const_p(const char *, data->list); } /* Return parametric option from a given service. Type is a part of option before ':' */ diff --git a/source3/passdb/pdb_get_set.c b/source3/passdb/pdb_get_set.c index 0d7f4cb..1b716f4 100644 --- a/source3/passdb/pdb_get_set.c +++ b/source3/passdb/pdb_get_set.c @@ -1001,6 +1001,7 @@ bool pdb_set_plaintext_passwd(struct samu *sampass, const char *plaintext) uchar *pwhistory; uint32_t pwHistLen; uint32_t current_history_len; -- Samba Shared Repository