mirror of
https://github.com/samba-team/samba.git
synced 2025-01-12 09:18:10 +03:00
sync small fixes from 3.0 and fix compiler warning in priv code
This commit is contained in:
parent
ce49e4f2b9
commit
c640594c93
@ -69,6 +69,7 @@ CONFIGLIBDIR = $(LIBDIR)/config
|
|||||||
CONFIGDIR = @configdir@
|
CONFIGDIR = @configdir@
|
||||||
VARDIR = @localstatedir@
|
VARDIR = @localstatedir@
|
||||||
MANDIR = @mandir@
|
MANDIR = @mandir@
|
||||||
|
DATADIR = @datadir@
|
||||||
|
|
||||||
# The permissions to give the executables
|
# The permissions to give the executables
|
||||||
INSTALLPERMS = 0755
|
INSTALLPERMS = 0755
|
||||||
|
@ -27,19 +27,17 @@ AC_ARG_WITH(fhs,
|
|||||||
[ --with-fhs Use FHS-compliant paths (default=no)],
|
[ --with-fhs Use FHS-compliant paths (default=no)],
|
||||||
[ case "$withval" in
|
[ case "$withval" in
|
||||||
yes)
|
yes)
|
||||||
configdir="${sysconfdir}/samba"
|
|
||||||
lockdir="\${VARDIR}/lib/samba"
|
lockdir="\${VARDIR}/lib/samba"
|
||||||
piddir="\${VARDIR}/run"
|
piddir="\${VARDIR}/run"
|
||||||
mandir="\${prefix}/share/man"
|
mandir="\${prefix}/share/man"
|
||||||
logfilebase="\${VARDIR}/log/samba"
|
logfilebase="\${VARDIR}/log/samba"
|
||||||
privatedir="\${CONFIGDIR}/private"
|
privatedir="\${CONFIGDIR}/private"
|
||||||
libdir="\${prefix}/lib/samba"
|
libdir="\${prefix}/lib/samba"
|
||||||
swatdir="\${prefix}/share/samba/swat"
|
configdir="${sysconfdir}/samba"
|
||||||
|
swatdir="\${DATADIR}/samba/swat",
|
||||||
;;
|
;;
|
||||||
esac])
|
esac])
|
||||||
|
|
||||||
lmhostsfile="\${CONFIGDIR}/lmhosts"
|
|
||||||
|
|
||||||
#################################################
|
#################################################
|
||||||
# set private directory location
|
# set private directory location
|
||||||
AC_ARG_WITH(privatedir,
|
AC_ARG_WITH(privatedir,
|
||||||
@ -929,8 +927,6 @@ AC_CHECK_FUNCS(syslog vsyslog timegm)
|
|||||||
AC_CHECK_FUNCS(setlocale nl_langinfo)
|
AC_CHECK_FUNCS(setlocale nl_langinfo)
|
||||||
# setbuffer, shmget, shm_open are needed for smbtorture
|
# setbuffer, shmget, shm_open are needed for smbtorture
|
||||||
AC_CHECK_FUNCS(setbuffer shmget shm_open backtrace_symbols)
|
AC_CHECK_FUNCS(setbuffer shmget shm_open backtrace_symbols)
|
||||||
|
|
||||||
# IRIX stack backtrace
|
|
||||||
AC_CHECK_HEADERS(libexc.h)
|
AC_CHECK_HEADERS(libexc.h)
|
||||||
AC_CHECK_LIB(exc, trace_back_stack)
|
AC_CHECK_LIB(exc, trace_back_stack)
|
||||||
|
|
||||||
@ -2960,7 +2956,7 @@ fi
|
|||||||
|
|
||||||
|
|
||||||
dictpath="/usr/lib/cracklib_dict"
|
dictpath="/usr/lib/cracklib_dict"
|
||||||
|
with_cracklib=yes
|
||||||
###############################################
|
###############################################
|
||||||
# test for where we get FaciestCheck from
|
# test for where we get FaciestCheck from
|
||||||
AC_MSG_CHECKING(where to use cracklib from (default=$dictpath))
|
AC_MSG_CHECKING(where to use cracklib from (default=$dictpath))
|
||||||
@ -3326,6 +3322,7 @@ AC_TRY_COMPILE([
|
|||||||
#define NO_PROTO_H 1
|
#define NO_PROTO_H 1
|
||||||
#define NO_CONFIG_H 1
|
#define NO_CONFIG_H 1
|
||||||
#define HAVE_SYS_QUOTAS 1
|
#define HAVE_SYS_QUOTAS 1
|
||||||
|
#include "${srcdir-.}/${samba_cv_sysquotas_file}"
|
||||||
#include "${srcdir-.}/lib/sysquotas.c"
|
#include "${srcdir-.}/lib/sysquotas.c"
|
||||||
],[],samba_cv_SYSQUOTA_WORKS=yes,samba_cv_SYSQUOTA_WORKS=no)
|
],[],samba_cv_SYSQUOTA_WORKS=yes,samba_cv_SYSQUOTA_WORKS=no)
|
||||||
CPPFLAGS="$SAVE_CPPFLAGS"
|
CPPFLAGS="$SAVE_CPPFLAGS"
|
||||||
|
@ -32,7 +32,7 @@ typedef struct _tree_node {
|
|||||||
typedef struct _tree_root {
|
typedef struct _tree_root {
|
||||||
TREE_NODE *root;
|
TREE_NODE *root;
|
||||||
int (*compare)(void* x, void *y);
|
int (*compare)(void* x, void *y);
|
||||||
void (*free)(void *p);
|
void (*free_func)(void *p);
|
||||||
} SORTED_TREE;
|
} SORTED_TREE;
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
@ -65,7 +65,7 @@ SORTED_TREE* sorted_tree_init( void *data_p,
|
|||||||
ZERO_STRUCTP( tree );
|
ZERO_STRUCTP( tree );
|
||||||
|
|
||||||
tree->compare = cmp_fn;
|
tree->compare = cmp_fn;
|
||||||
tree->free = free_fn;
|
tree->free_func = free_fn;
|
||||||
|
|
||||||
if ( !(tree->root = (TREE_NODE*)malloc( sizeof(TREE_NODE) )) ) {
|
if ( !(tree->root = (TREE_NODE*)malloc( sizeof(TREE_NODE) )) ) {
|
||||||
SAFE_FREE( tree );
|
SAFE_FREE( tree );
|
||||||
@ -110,8 +110,8 @@ void sorted_tree_destroy( SORTED_TREE *tree )
|
|||||||
if ( tree->root )
|
if ( tree->root )
|
||||||
sorted_tree_destroy_children( tree->root );
|
sorted_tree_destroy_children( tree->root );
|
||||||
|
|
||||||
if ( tree->free )
|
if ( tree->free_func )
|
||||||
tree->free( tree->root );
|
tree->free_func( tree->root );
|
||||||
|
|
||||||
SAFE_FREE( tree );
|
SAFE_FREE( tree );
|
||||||
}
|
}
|
||||||
|
@ -1110,7 +1110,7 @@ size_t pull_ucs2(const void *base_ptr, char *dest, const void *src, size_t dest_
|
|||||||
|
|
||||||
if (ucs2_align(base_ptr, src, flags)) {
|
if (ucs2_align(base_ptr, src, flags)) {
|
||||||
src = (const void *)((const char *)src + 1);
|
src = (const void *)((const char *)src + 1);
|
||||||
if (src_len > 0)
|
if (src_len != (size_t)-1)
|
||||||
src_len--;
|
src_len--;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1204,7 +1204,7 @@ static int tdbsam_traverse_privilege(TDB_CONTEXT *t, TDB_DATA key, TDB_DATA data
|
|||||||
int len;
|
int len;
|
||||||
|
|
||||||
s = data.dptr;
|
s = data.dptr;
|
||||||
while (c = strchr(s, ',')) {
|
while ((c=strchr(s, ',')) !=NULL) {
|
||||||
len = MAX((c - s), strlen(pt->sid_list[i]));
|
len = MAX((c - s), strlen(pt->sid_list[i]));
|
||||||
if (strncmp(s, pt->sid_list[i], len) == 0) {
|
if (strncmp(s, pt->sid_list[i], len) == 0) {
|
||||||
DEBUG(10, ("sid [%s] found in users sid list\n", pt->sid_list[i]));
|
DEBUG(10, ("sid [%s] found in users sid list\n", pt->sid_list[i]));
|
||||||
|
Loading…
Reference in New Issue
Block a user