From 22147952b744958ec46d356e942540356ff7d93e Mon Sep 17 00:00:00 2001 From: Werner Koch Date: Mon, 22 Jun 2015 20:54:23 +0200 Subject: common: Add function parse_debug_flag * common/miscellaneous.c (parse_debug_flag): New. * common/util.h (struct debug_flags_s): New. Signed-off-by: Werner Koch --- common/util.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'common/util.h') diff --git a/common/util.h b/common/util.h index 82e9887d6..d5ddc1f13 100644 --- a/common/util.h +++ b/common/util.h @@ -389,6 +389,14 @@ int match_multistr (const char *multistr,const char *match); int gnupg_compare_version (const char *a, const char *b); +struct debug_flags_s +{ + unsigned int flag; + const char *name; +}; +int parse_debug_flag (const char *string, unsigned int *debugvar, + const struct debug_flags_s *flags); + /*-- Simple replacement functions. */ -- cgit v1.2.3