summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
Diffstat (limited to 'source3')
-rw-r--r--source3/include/printing.h6
-rw-r--r--source3/printing/printing_db.c2
-rw-r--r--source3/smbd/proto.h5
-rw-r--r--source3/smbd/statcache.c2
4 files changed, 9 insertions, 6 deletions
diff --git a/source3/include/printing.h b/source3/include/printing.h
index bba7d53a16..1bbb72c7be 100644
--- a/source3/include/printing.h
+++ b/source3/include/printing.h
@@ -24,6 +24,7 @@
This file defines the low-level printing system interfaces used by the
SAMBA printing subsystem.
*/
+#include "tdb_compat.h"
/* Extra fields above "LPQ_PRINTING" are used to map extra NT status codes. */
@@ -158,9 +159,6 @@ extern struct printif iprint_printif;
/* There can be this many printing tdb's open, plus any locked ones. */
#define MAX_PRINT_DBS_OPEN 1
-struct TDB_DATA;
-struct tdb_context;
-
struct tdb_print_db {
struct tdb_print_db *next, *prev;
struct tdb_context *tdb;
@@ -252,7 +250,7 @@ uint32_t print_parse_jobid(const char *fname);
struct tdb_print_db *get_print_db_byname(const char *printername);
void release_print_db( struct tdb_print_db *pdb);
void close_all_print_db(void);
-struct TDB_DATA get_printer_notify_pid_list(struct tdb_context *tdb, const char *printer_name, bool cleanlist);
+TDB_DATA get_printer_notify_pid_list(struct tdb_context *tdb, const char *printer_name, bool cleanlist);
void print_queue_receive(struct messaging_context *msg,
void *private_data,
diff --git a/source3/printing/printing_db.c b/source3/printing/printing_db.c
index b836c2145b..e442551b83 100644
--- a/source3/printing/printing_db.c
+++ b/source3/printing/printing_db.c
@@ -160,7 +160,7 @@ void close_all_print_db(void)
messages. data needs freeing on exit.
****************************************************************************/
-struct TDB_DATA get_printer_notify_pid_list(struct tdb_context *tdb, const char *printer_name, bool cleanlist)
+TDB_DATA get_printer_notify_pid_list(struct tdb_context *tdb, const char *printer_name, bool cleanlist)
{
TDB_DATA data;
size_t i;
diff --git a/source3/smbd/proto.h b/source3/smbd/proto.h
index 486ff33598..6e515278b4 100644
--- a/source3/smbd/proto.h
+++ b/source3/smbd/proto.h
@@ -1049,8 +1049,13 @@ bool stat_cache_lookup(connection_struct *conn,
void send_stat_cache_delete_message(struct messaging_context *msg_ctx,
const char *name);
void stat_cache_delete(const char *name);
+#if BUILD_TDB2
+struct tdb_data;
+unsigned int fast_string_hash(struct tdb_data *key);
+#else
struct TDB_DATA;
unsigned int fast_string_hash(struct TDB_DATA *key);
+#endif
bool reset_stat_cache( void );
/* The following definitions come from smbd/statvfs.c */
diff --git a/source3/smbd/statcache.c b/source3/smbd/statcache.c
index e1597fdd58..b0904c9ff7 100644
--- a/source3/smbd/statcache.c
+++ b/source3/smbd/statcache.c
@@ -377,7 +377,7 @@ void stat_cache_delete(const char *name)
JRA. Use a djb-algorithm hash for speed.
***************************************************************/
-unsigned int fast_string_hash(struct TDB_DATA *key)
+unsigned int fast_string_hash(TDB_DATA *key)
{
unsigned int n = 0;
const char *p;