chiark
/
gitweb
/
~yarrgweb
/
ypp-sc-tools.web-live.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
progress displaying; some client window geometry checking
[ypp-sc-tools.web-live.git]
/
pctb
/
ocr.h
diff --git
a/pctb/ocr.h
b/pctb/ocr.h
index 5b5f697dbd88603a37dd8f518f91308c39192dfb..5371c75b631ac61ea29db285d883ffc99c416875 100644
(file)
--- a/
pctb/ocr.h
+++ b/
pctb/ocr.h
@@
-83,14
+83,17
@@
void debug_flush(void);
const char *get_vardir(void);
const char *get_vardir(void);
+#define DEFINE_VWRAPPERF(decls, funcf) \
+ decls void funcf(const char *fmt, ...) { \
+ va_list al; va_start(al,fmt); v##funcf(fmt,al); va_end(al); \
+ }
+
#define DEBUG_DEFINE_SOME_DEBUGF(fl,funcf) \
static void v##funcf(const char *fmt, va_list al) { \
if (DEBUGP(fl)) \
vfprintf(debug,fmt,al); \
} \
#define DEBUG_DEFINE_SOME_DEBUGF(fl,funcf) \
static void v##funcf(const char *fmt, va_list al) { \
if (DEBUGP(fl)) \
vfprintf(debug,fmt,al); \
} \
- static void funcf(const char *fmt, ...) { \
- va_list al; va_start(al,fmt); v##funcf(fmt,al); va_end(al); \
- }
+ DEFINE_VWRAPPERF(static, funcf)
#define DEBUG_DEFINE_DEBUGF(fl) DEBUG_DEFINE_SOME_DEBUGF(fl,debugf)
#define DEBUG_DEFINE_DEBUGF(fl) DEBUG_DEFINE_SOME_DEBUGF(fl,debugf)