1
0
mirror of https://github.com/samba-team/samba.git synced 2025-02-03 13:47:25 +03:00

s3:dbwrap: do not burden the user of db_open_ctdb with ifdef voodoo

Signed-off-by: Michael Adam <obnox@samba.org>
This commit is contained in:
Gregor Beck 2011-10-25 16:32:12 +02:00 committed by Michael Adam
parent 90eb2eb178
commit a719ce7c11
2 changed files with 13 additions and 3 deletions

View File

@ -22,6 +22,7 @@
#include "system/filesys.h"
#include "lib/util/tdb_wrap.h"
#include "util_tdb.h"
#include "dbwrap/dbwrap_ctdb.h"
#include "dbwrap/dbwrap_rbt.h"
#include "lib/param/param.h"
@ -1526,4 +1527,16 @@ struct db_context *db_open_ctdb(TALLOC_CTX *mem_ctx,
return result;
}
#else /* CLUSTER_SUPPORT */
struct db_context *db_open_ctdb(TALLOC_CTX *mem_ctx,
const char *name,
int hash_size, int tdb_flags,
int open_flags, mode_t mode)
{
DEBUG(3, ("db_open_ctdb: no cluster support!\n"));
return NULL;
}
#endif

View File

@ -21,8 +21,6 @@
#ifndef __DBWRAP_CTDB_H__
#define __DBWRAP_CTDB_H__
#ifdef CLUSTER_SUPPORT
#include <talloc.h>
struct db_context;
@ -31,6 +29,5 @@ struct db_context *db_open_ctdb(TALLOC_CTX *mem_ctx,
const char *name,
int hash_size, int tdb_flags,
int open_flags, mode_t mode);
#endif /* CLUSTER_SUPPORT */
#endif /* __DBWRAP_CTDB_H__ */