mirror of
https://github.com/samba-team/samba.git
synced 2025-01-11 05:18:09 +03:00
tdb: Add tdb_trace_1plusn_rec_flag_ret
Needed for tdb_storev Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Ralph Boehme <slow@samba.org>
This commit is contained in:
parent
37e644fc20
commit
647e61b0e8
@ -1214,6 +1214,25 @@ void tdb_trace_2rec_flag_ret(struct tdb_context *tdb, const char *op,
|
||||
tdb_trace_end_ret(tdb, ret);
|
||||
}
|
||||
|
||||
void tdb_trace_1plusn_rec_flag_ret(struct tdb_context *tdb, const char *op,
|
||||
TDB_DATA rec,
|
||||
const TDB_DATA *recs, int num_recs,
|
||||
unsigned flag, int ret)
|
||||
{
|
||||
char msg[1 + sizeof(ret) * 4];
|
||||
int i;
|
||||
|
||||
snprintf(msg, sizeof(msg), " %#x", flag);
|
||||
tdb_trace_start(tdb);
|
||||
tdb_trace_write(tdb, op);
|
||||
tdb_trace_record(tdb, rec);
|
||||
for (i=0; i<num_recs; i++) {
|
||||
tdb_trace_record(tdb, recs[i]);
|
||||
}
|
||||
tdb_trace_write(tdb, msg);
|
||||
tdb_trace_end_ret(tdb, ret);
|
||||
}
|
||||
|
||||
void tdb_trace_2rec_retrec(struct tdb_context *tdb, const char *op,
|
||||
TDB_DATA rec1, TDB_DATA rec2, TDB_DATA ret)
|
||||
{
|
||||
|
@ -96,6 +96,10 @@ void tdb_trace_1rec_retrec(struct tdb_context *tdb, const char *op,
|
||||
void tdb_trace_2rec_flag_ret(struct tdb_context *tdb, const char *op,
|
||||
TDB_DATA rec1, TDB_DATA rec2, unsigned flag,
|
||||
int ret);
|
||||
void tdb_trace_1plusn_rec_flag_ret(struct tdb_context *tdb, const char *op,
|
||||
TDB_DATA rec,
|
||||
const TDB_DATA *recs, int num_recs,
|
||||
unsigned flag, int ret);
|
||||
void tdb_trace_2rec_retrec(struct tdb_context *tdb, const char *op,
|
||||
TDB_DATA rec1, TDB_DATA rec2, TDB_DATA ret);
|
||||
#else
|
||||
@ -108,6 +112,7 @@ void tdb_trace_2rec_retrec(struct tdb_context *tdb, const char *op,
|
||||
#define tdb_trace_1rec_ret(tdb, op, rec, ret)
|
||||
#define tdb_trace_1rec_retrec(tdb, op, rec, ret)
|
||||
#define tdb_trace_2rec_flag_ret(tdb, op, rec1, rec2, flag, ret)
|
||||
#define tdb_trace_1plusn_rec_flag_ret(tdb, op, rec, recs, num_recs, flag, ret);
|
||||
#define tdb_trace_2rec_retrec(tdb, op, rec1, rec2, ret)
|
||||
#endif /* !TDB_TRACE */
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user