diff options
author | Herb Lewis <herb@samba.org> | 2005-05-02 17:49:43 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 10:56:46 -0500 |
commit | 1c4bbe06549d86614318718a45b9bc48e3bfc81f (patch) | |
tree | 121ab409dccc32c6d0f4ea7289d95843780225ce | |
parent | 714a426fe579ad481aa342a8d4cfd5331a12978f (diff) | |
download | samba-1c4bbe06549d86614318718a45b9bc48e3bfc81f.tar.gz samba-1c4bbe06549d86614318718a45b9bc48e3bfc81f.tar.bz2 samba-1c4bbe06549d86614318718a45b9bc48e3bfc81f.zip |
r6586: get rid of a few more compiler warnings
(This used to be commit 173375f8d88bf8e8db8d60e5d5f0e5dcc28767d9)
-rw-r--r-- | source3/lib/dummyroot.c | 3 | ||||
-rw-r--r-- | source3/lib/dummysmbd.c | 2 | ||||
-rw-r--r-- | source3/lib/interfaces.c | 2 | ||||
-rw-r--r-- | source3/lib/sysquotas.c | 2 | ||||
-rw-r--r-- | source3/lib/sysquotas_4A.c | 2 | ||||
-rw-r--r-- | source3/lib/sysquotas_linux.c | 2 | ||||
-rw-r--r-- | source3/lib/sysquotas_xfs.c | 2 | ||||
-rw-r--r-- | source3/libads/kerberos.c | 2 | ||||
-rw-r--r-- | source3/libsmb/clikrb5.c | 4 | ||||
-rw-r--r-- | source3/smbd/notify_kernel.c | 2 | ||||
-rw-r--r-- | source3/smbd/oplock_linux.c | 2 | ||||
-rw-r--r-- | source3/tests/shlib.c | 2 | ||||
-rw-r--r-- | source3/tests/sysquotas.c | 2 | ||||
-rw-r--r-- | source3/torture/denytest.c | 4 | ||||
-rw-r--r-- | source3/torture/mangle_test.c | 3 | ||||
-rw-r--r-- | source3/torture/torture.c | 5 |
16 files changed, 34 insertions, 7 deletions
diff --git a/source3/lib/dummyroot.c b/source3/lib/dummyroot.c index c8465cb791..75263ed232 100644 --- a/source3/lib/dummyroot.c +++ b/source3/lib/dummyroot.c @@ -22,6 +22,9 @@ /* Stupid dummy functions required due to the horrible dependency mess in Samba. */ +void become_root(void); +void unbecome_root(void); + void become_root(void) { return; diff --git a/source3/lib/dummysmbd.c b/source3/lib/dummysmbd.c index 17bc321774..153ca5cd8c 100644 --- a/source3/lib/dummysmbd.c +++ b/source3/lib/dummysmbd.c @@ -22,6 +22,8 @@ /* Stupid dummy functions required due to the horrible dependency mess in Samba. */ +void decrement_smbd_process_count( void ); + void decrement_smbd_process_count( void ) { return; diff --git a/source3/lib/interfaces.c b/source3/lib/interfaces.c index 96f4b4cd94..dc30bdce47 100644 --- a/source3/lib/interfaces.c +++ b/source3/lib/interfaces.c @@ -358,6 +358,8 @@ static int iface_comp(struct iface_struct *i1, struct iface_struct *i2) /* this wrapper is used to remove duplicates from the interface list generated above */ +int get_interfaces(struct iface_struct *ifaces, int max_interfaces); + int get_interfaces(struct iface_struct *ifaces, int max_interfaces) { int total, i, j; diff --git a/source3/lib/sysquotas.c b/source3/lib/sysquotas.c index 61e2382bc9..52a598a4e6 100644 --- a/source3/lib/sysquotas.c +++ b/source3/lib/sysquotas.c @@ -497,6 +497,8 @@ int sys_set_quota(const char *path, enum SMB_QUOTA_TYPE qtype, unid_t id, SMB_DI } #else /* HAVE_SYS_QUOTAS */ + void dummy_sysquotas_c(void); + void dummy_sysquotas_c(void) { return; diff --git a/source3/lib/sysquotas_4A.c b/source3/lib/sysquotas_4A.c index ffb4123799..5a7d84fca9 100644 --- a/source3/lib/sysquotas_4A.c +++ b/source3/lib/sysquotas_4A.c @@ -335,5 +335,7 @@ int sys_set_vfs_quota(const char *path, const char *bdev, enum SMB_QUOTA_TYPE qt } #else /* HAVE_QUOTACTL_4A */ + void dummy_sysquotas_4A(void); + void dummy_sysquotas_4A(void){} #endif /* HAVE_QUOTACTL_4A */ diff --git a/source3/lib/sysquotas_linux.c b/source3/lib/sysquotas_linux.c index 3867c1b0f9..4c024b04cc 100644 --- a/source3/lib/sysquotas_linux.c +++ b/source3/lib/sysquotas_linux.c @@ -556,5 +556,7 @@ int sys_set_vfs_quota(const char *path, const char *bdev, enum SMB_QUOTA_TYPE qt } #else /* HAVE_QUOTACTL_LINUX */ + void dummy_sysquotas_linux(void); + void dummy_sysquotas_linux(void){} #endif /* HAVE_QUOTACTL_LINUX */ diff --git a/source3/lib/sysquotas_xfs.c b/source3/lib/sysquotas_xfs.c index 9fe4ec0d99..950fb30f04 100644 --- a/source3/lib/sysquotas_xfs.c +++ b/source3/lib/sysquotas_xfs.c @@ -329,5 +329,7 @@ int sys_set_xfs_quota(const char *path, const char *bdev, enum SMB_QUOTA_TYPE qt } #else /* HAVE_XFS_QUOTAS */ + void dummy_sysquotas_xfs(void); + void dummy_sysquotas_xfs(void){} #endif /* HAVE_XFS_QUOTAS */ diff --git a/source3/libads/kerberos.c b/source3/libads/kerberos.c index 18820d9e31..902feb2eee 100644 --- a/source3/libads/kerberos.c +++ b/source3/libads/kerberos.c @@ -248,7 +248,7 @@ krb5_principal kerberos_fetch_salt_princ_for_host_princ(krb5_context context, Setting principal to NULL deletes this entry. ************************************************************************/ - BOOL kerberos_secrets_store_salting_principal(const char *service, +BOOL kerberos_secrets_store_salting_principal(const char *service, int enctype, const char *principal) { diff --git a/source3/libsmb/clikrb5.c b/source3/libsmb/clikrb5.c index 43252b94d8..e70c2b8bec 100644 --- a/source3/libsmb/clikrb5.c +++ b/source3/libsmb/clikrb5.c @@ -525,11 +525,13 @@ failed: #if defined(HAVE_KRB5_PRINCIPAL_GET_COMP_STRING) && !defined(HAVE_KRB5_PRINC_COMPONENT) + const krb5_data *krb5_princ_component(krb5_context context, krb5_principal principal, int i ); + const krb5_data *krb5_princ_component(krb5_context context, krb5_principal principal, int i ) { static krb5_data kdata; - kdata.data = krb5_principal_get_comp_string(context, principal, i); + kdata.data = (char *)krb5_principal_get_comp_string(context, principal, i); kdata.length = strlen(kdata.data); return &kdata; } diff --git a/source3/smbd/notify_kernel.c b/source3/smbd/notify_kernel.c index c368fd79a1..5c9d885eed 100644 --- a/source3/smbd/notify_kernel.c +++ b/source3/smbd/notify_kernel.c @@ -243,5 +243,7 @@ struct cnotify_fns *kernel_notify_init(void) } #else + void notify_kernel_dummy(void); + void notify_kernel_dummy(void) {} #endif /* HAVE_KERNEL_CHANGE_NOTIFY */ diff --git a/source3/smbd/oplock_linux.c b/source3/smbd/oplock_linux.c index 5d6bdb9883..6d1bc64ce1 100644 --- a/source3/smbd/oplock_linux.c +++ b/source3/smbd/oplock_linux.c @@ -311,5 +311,7 @@ struct kernel_oplocks *linux_init_kernel_oplocks(void) return &koplocks; } #else + void oplock_linux_dummy(void); + void oplock_linux_dummy(void) {} #endif /* HAVE_KERNEL_OPLOCKS_LINUX */ diff --git a/source3/tests/shlib.c b/source3/tests/shlib.c index 761d9fd5c5..eddb76ff2a 100644 --- a/source3/tests/shlib.c +++ b/source3/tests/shlib.c @@ -1,5 +1,7 @@ /* a trivial function used to test building shared libraries */ +int foo(void); + int foo(void) { return 1; diff --git a/source3/tests/sysquotas.c b/source3/tests/sysquotas.c index 48a34feb13..bf16c8ba6e 100644 --- a/source3/tests/sysquotas.c +++ b/source3/tests/sysquotas.c @@ -28,6 +28,8 @@ #define SYS_DQBLK dqblk #endif + int autoconf_quota(void); + int autoconf_quota(void) { int ret = -1; diff --git a/source3/torture/denytest.c b/source3/torture/denytest.c index 89b0fdf93f..a130b59815 100644 --- a/source3/torture/denytest.c +++ b/source3/torture/denytest.c @@ -1556,8 +1556,8 @@ BOOL torture_denytest2(int dummy) resultstr(denytable2[i].result)); } - cli_close(cli1, fnum1); - cli_close(cli2, fnum2); + if (fnum1 != -1) cli_close(cli1, fnum1); + if (fnum2 != -1) cli_close(cli2, fnum2); } for (i=0;i<2;i++) { diff --git a/source3/torture/mangle_test.c b/source3/torture/mangle_test.c index 5acad2d015..df0855d93d 100644 --- a/source3/torture/mangle_test.c +++ b/source3/torture/mangle_test.c @@ -20,6 +20,8 @@ #include "includes.h" +extern int torture_numops; + static TDB_CONTEXT *tdb; #define NAME_LENGTH 20 @@ -159,7 +161,6 @@ static void gen_name(char *name) BOOL torture_mangle(int dummy) { - extern int torture_numops; static struct cli_state *cli; int i; BOOL ret = True; diff --git a/source3/torture/torture.c b/source3/torture/torture.c index b1ed1e4e37..ef9497d9ad 100644 --- a/source3/torture/torture.c +++ b/source3/torture/torture.c @@ -22,6 +22,9 @@ #include "includes.h" +extern char *optarg; +extern int optind; + static fstring host, workgroup, share, password, username, myname; static int max_protocol = PROTOCOL_NT1; static const char *sockops="TCP_NODELAY"; @@ -4902,8 +4905,6 @@ static void usage(void) char *p; int gotuser = 0; int gotpass = 0; - extern char *optarg; - extern int optind; BOOL correct = True; dbf = x_stdout; |