summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJeremy Harris <jgh146exb@wizmail.org>2017-10-06 22:18:30 +0100
committerJeremy Harris <jgh146exb@wizmail.org>2017-10-06 22:58:02 +0100
commit552f4602b9d36667cd4a1ffaad4ce74ed7d1c922 (patch)
treedec9f791b5e06d623973f54bf146793d2b4cb656 /src
parent1b7cf216d933b395dee691f05becca4dd44b26f7 (diff)
Use flag names rather than values in debug output
The values differ between Linux and FreeBSD
Diffstat (limited to 'src')
-rw-r--r--src/src/dbstuff.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/src/dbstuff.h b/src/src/dbstuff.h
index aec549f48..1bc4e1eae 100644
--- a/src/src/dbstuff.h
+++ b/src/src/dbstuff.h
@@ -632,8 +632,12 @@ after reading data. */
# define EXIM_DBOPEN(name, dirname, flags, mode, dbpp) \
do { \
DEBUG(D_hints_lookup) \
- debug_printf("EXIM_DBOPEN: file <%s> dir <%s> flags 0x%x\n", \
- (name), (dirname), flags); \
+ debug_printf("EXIM_DBOPEN: file <%s> dir <%s> flags=%s\n", \
+ (name), (dirname), \
+ (flags) == O_RDONLY ? "O_RDONLY" \
+ : (flags) == O_RDWR ? "O_RDWR" \
+ : (flags) == (O_RDWR|O_CREAT) ? "O_RDWR|O_CREAT" \
+ : "??"); \
EXIM_DBOPEN__(name, dirname, flags, mode, dbpp); \
DEBUG(D_hints_lookup) debug_printf("returned from EXIM_DBOPEN: %p\n", *dbpp); \
} while(0)